パッケージ org.aiwolf.common.util
クラス BidiMap<K,V>
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<K,V>
org.aiwolf.common.util.BidiMap<K,V>
- 型パラメータ:
K
-キーKeyV
-値Value
- すべての実装されたインタフェース:
Serializable
,Cloneable
,Map<K,
V>
双方向マップです。
Bidimap.
- 関連項目:
-
ネストされたクラスの概要
クラスから継承されたネストされたクラス/インタフェース java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,
V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
コンストラクタの概要
コンストラクタ -
メソッドの概要
クラスから継承されたメソッド java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
クラスから継承されたメソッド java.util.AbstractMap
equals, hashCode, toString
-
コンストラクタの詳細
-
BidiMap
public BidiMap()新しいBidiMapを構築します。Create new BidiMap. -
BidiMap
public BidiMap(int initialCapacity, float loadFactor) 指定された初期容量と負荷係数を持つ、 空のBidiMapを作成します。Constructs an empty BidiMap with the specified initial capacity and load factor.- パラメータ:
initialCapacity
-初期容量The initial capacityloadFactor
-負荷係数The load factor
-
BidiMap
public BidiMap(int initialCapacity) 指定された初期容量とデフォルトの負荷係数(0.75)を持つ、 空のBidiMapを作成します。Constructs an empty HashMap with the specified initial capacity and the default load factor (0.75).- パラメータ:
initialCapacity
-初期容量The initial capacity
-
BidiMap
指定されたMapと同じマッピングで新しいBidiMapを 作成します。デフォルトの負荷係数(0.75)、および指定 されたMapのマッピングを保持するのに十分な初期容量で、 BidiMapは作成されます。Constructs a new BidiMap with the same mappings as the specified Map. The BidiMap is created with default load factor (0.75) and an initial capacity sufficient to hold the mappings in the specified Map.- パラメータ:
m
-マッピングがこのマップに配置されるマップThe map whose mappings are to be placed in this map- 例外:
NullPointerException
-指定されたマップがnullの場合If the specified map is null
-
-
メソッドの詳細
-
put
-
putAll
-
getKey
指定された値に関連付けられたキーを返します。Get the key.- パラメータ:
value
-値Value- 戻り値:
- キーKey
-
removeValue
指定された値とそのキーを削除します。Remove the value and key.- パラメータ:
value
-値Value- 戻り値:
- 値に以前関連付けられていたキーKey that related to the value
-
clear
public void clear()
-