|
Enhanced C#
Loyc library documentation
|
Represents a pool of objects in which an object is automatically created when requested by its key. More...
Represents a pool of objects in which an object is automatically created when requested by its key.
| TKey | Key type. |
| TValue | Value type. |
This design assumes that the values in the pool know their own key, so it implements IEnumerable{TValue} rather than IEnumerable{KeyValuePair{TKey,TValue}}.
Public Member Functions | |
| TValue | GetIfExists (TKey key) |
| Gets the item with the specified key, if it was created earlier. More... | |
Additional Inherited Members | |
Properties inherited from Loyc.Collections.IIndexed< in K, out V > | |
| V | this[K key] [get] |
| Gets the value associated with the specified key. More... | |
| TValue Loyc.Collections.IAutoCreatePool< in TKey, out TValue >.GetIfExists | ( | TKey | key | ) |
Gets the item with the specified key, if it was created earlier.
default(TValue) if the value has not been created.
1.8.7