GetOrAdd<T>(Func<T>)
Gets a value from the cache or adds it if it does not exist yet.
Declaration
T GetOrAdd<T>(Func<T> getter)
Parameters
Type | Name | Description |
---|---|---|
Func<T> | getter | The delegate invoked if no value of type |
Returns
Type | Description |
---|---|
T | Either the value of type |
Type Parameters
Name | Description |
---|---|
T | Type of the value. |