Class IngredientTreeMap<T,M,V>
java.lang.Object
org.cyclops.cyclopscore.ingredient.collection.IngredientMapAdapter<T,M,V>
org.cyclops.cyclopscore.ingredient.collection.IngredientMapWrappedAdapter<T,M,V,TreeMap<IngredientInstanceWrapper<T,M>,V>>
org.cyclops.cyclopscore.ingredient.collection.IngredientTreeMap<T,M,V>
- Type Parameters:
T
- The instance type.M
- The matching condition parameter.V
- The type of mapped values.
- All Implemented Interfaces:
Iterable<Map.Entry<T,
,V>> IIngredientCollectionLike<T,
,M, Map.Entry<T, V>> IIngredientMap<T,
,M, V> IIngredientMapMutable<T,
M, V>
public class IngredientTreeMap<T,M,V>
extends IngredientMapWrappedAdapter<T,M,V,TreeMap<IngredientInstanceWrapper<T,M>,V>>
An ingredient map collection that internally uses an
TreeMap
to store instances.
This means that key instances are automatically ordered based on their component type's comparator.- See Also:
-
Constructor Summary
ConstructorDescriptionIngredientTreeMap
(IngredientComponent<T, M> component) IngredientTreeMap
(IngredientComponent<T, M> component, TreeMap<IngredientInstanceWrapper<T, M>, V> map) IngredientTreeMap
(IngredientComponent<T, M> component, IIngredientMap<? extends T, M, ? extends V> map) -
Method Summary
Methods inherited from class org.cyclops.cyclopscore.ingredient.collection.IngredientMapWrappedAdapter
clear, containsValue, get, getCollection, iterator, put, remove, size, values, wrap
Methods inherited from class org.cyclops.cyclopscore.ingredient.collection.IngredientMapAdapter
entrySet, equals, getAll, getComponent, hashCode, iterator, keySet, removeAll, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.cyclops.cyclopscore.ingredient.collection.IIngredientCollectionLike
isEmpty
Methods inherited from interface org.cyclops.cyclopscore.ingredient.collection.IIngredientMap
containsKey, containsKey, containsKeyAll, containsKeyAll, countKey
Methods inherited from interface org.cyclops.cyclopscore.ingredient.collection.IIngredientMapMutable
putAll, removeAll, removeAll
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
IngredientTreeMap
-
IngredientTreeMap
public IngredientTreeMap(IngredientComponent<T, M> component, IIngredientMap<? extends T, M, ? extends V> map) -
IngredientTreeMap
public IngredientTreeMap(IngredientComponent<T, M> component, TreeMap<IngredientInstanceWrapper<T, M>, V> map)
-
-
Method Details
-
keySet
- Specified by:
keySet
in interfaceIIngredientMap<T,
M, V> - Overrides:
keySet
in classIngredientMapWrappedAdapter<T,
M, V, TreeMap<IngredientInstanceWrapper<T, M>, V>> - Returns:
- All key instances.
-