зеркало из https://github.com/SixLabors/docs-v1.git
467 строки
28 KiB
HTML
467 строки
28 KiB
HTML
<!DOCTYPE html>
|
|
<!--[if IE]><![endif]-->
|
|
<html>
|
|
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
|
<title>Class ConcurrentDictionaryExtensions
|
|
</title>
|
|
<meta name="viewport" content="width=device-width">
|
|
<meta name="title" content="Class ConcurrentDictionaryExtensions
|
|
">
|
|
<meta name="generator" content="docfx 2.59.0.0">
|
|
|
|
<link rel="shortcut icon" href="../../favicon.ico">
|
|
<link rel="stylesheet" href="../../styles/docfx.vendor.css">
|
|
<link rel="stylesheet" href="../../styles/docfx.css">
|
|
<link rel="stylesheet" href="../../styles/main.css">
|
|
<meta property="docfx:navrel" content="../../toc">
|
|
<meta property="docfx:tocrel" content="toc">
|
|
|
|
<meta property="docfx:rel" content="../../">
|
|
|
|
</head>
|
|
<body data-spy="scroll" data-target="#affix" data-offset="120">
|
|
<div id="wrapper">
|
|
<header>
|
|
|
|
<nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
|
|
<div class="container">
|
|
<div class="navbar-header">
|
|
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
|
|
<span class="sr-only">Toggle navigation</span>
|
|
<span class="icon-bar"></span>
|
|
<span class="icon-bar"></span>
|
|
<span class="icon-bar"></span>
|
|
</button>
|
|
|
|
<a class="navbar-brand" href="../../index.html">
|
|
<img id="logo" class="svg" src="../../logo.svg" alt="">
|
|
</a>
|
|
</div>
|
|
<div class="collapse navbar-collapse" id="navbar">
|
|
<form class="navbar-form navbar-right" role="search" id="search">
|
|
<div class="form-group">
|
|
<input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
|
|
</div>
|
|
</form>
|
|
|
|
<ul class="nav level1 navbar-nav">
|
|
<li>
|
|
<a href="../../articles/imagesharp/index.html" title="Articles">Articles</a>
|
|
</li>
|
|
<li>
|
|
<a href="../../api/index.html" title="API Documentation">API Documentation</a>
|
|
</li>
|
|
</ul> </div>
|
|
</div>
|
|
</nav>
|
|
|
|
<div class="subnav navbar navbar-default">
|
|
<div class="container hide-when-search" id="breadcrumb">
|
|
<ul class="breadcrumb">
|
|
<li></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</header>
|
|
<div class="container body-content">
|
|
|
|
<div id="search-results">
|
|
<div class="search-list">Search Results for <span></span></div>
|
|
<div class="sr-items">
|
|
<p><i class="glyphicon glyphicon-refresh index-loading"></i></p>
|
|
</div>
|
|
<ul id="pagination" data-first="First" data-prev="Previous" data-next="Next" data-last="Last"></ul>
|
|
</div>
|
|
</div>
|
|
<div role="main" class="container body-content hide-when-search">
|
|
<div class="sidenav hide-when-search">
|
|
<a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
|
|
<div class="sidetoggle collapse" id="sidetoggle">
|
|
<div>
|
|
<div class="sidefilter">
|
|
<form class="toc-filter">
|
|
<span class="glyphicon glyphicon-filter filter-icon"></span>
|
|
<input type="text" id="toc_filter_input" placeholder="Enter here to filter..." onkeypress="if(event.keyCode==13) {return false;}">
|
|
</form>
|
|
</div>
|
|
<div class="sidetoc">
|
|
<div class="toc" id="toc">
|
|
|
|
<ul class="nav level1">
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.html" title="SixLabors.ImageSharp.Web" class="">SixLabors.ImageSharp.Web</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.FormattedImage.html" title="FormattedImage" class="">FormattedImage</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.FormatUtilities.html" title="FormatUtilities" class="">FormatUtilities</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.ImageCacheMetadata.html" title="ImageCacheMetadata" class="">ImageCacheMetadata</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.ImageMetadata.html" title="ImageMetadata" class="">ImageMetadata</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Caching.html" title="SixLabors.ImageSharp.Web.Caching" class="">SixLabors.ImageSharp.Web.Caching</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Caching.CacheHash.html" title="CacheHash" class="">CacheHash</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Caching.ICacheHash.html" title="ICacheHash" class="">ICacheHash</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Caching.IImageCache.html" title="IImageCache" class="">IImageCache</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Caching.PhysicalFileSystemCache.html" title="PhysicalFileSystemCache" class="">PhysicalFileSystemCache</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Caching.PhysicalFileSystemCacheOptions.html" title="PhysicalFileSystemCacheOptions" class="">PhysicalFileSystemCacheOptions</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Commands.html" title="SixLabors.ImageSharp.Web.Commands" class="">SixLabors.ImageSharp.Web.Commands</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.CommandParser.html" title="CommandParser" class="">CommandParser</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.DictionaryExtensions.html" title="DictionaryExtensions" class="">DictionaryExtensions</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.IRequestParser.html" title="IRequestParser" class="">IRequestParser</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.PresetOnlyQueryCollectionRequestParser.html" title="PresetOnlyQueryCollectionRequestParser" class="">PresetOnlyQueryCollectionRequestParser</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.PresetOnlyQueryCollectionRequestParserOptions.html" title="PresetOnlyQueryCollectionRequestParserOptions" class="">PresetOnlyQueryCollectionRequestParserOptions</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.QueryCollectionRequestParser.html" title="QueryCollectionRequestParser" class="">QueryCollectionRequestParser</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Commands.Converters.html" title="SixLabors.ImageSharp.Web.Commands.Converters" class="">SixLabors.ImageSharp.Web.Commands.Converters</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.Converters.ICommandConverter.html" title="ICommandConverter" class="">ICommandConverter</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Commands.Converters.ICommandConverter-1.html" title="ICommandConverter<T>" class="">ICommandConverter<T></a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.html" title="SixLabors.ImageSharp.Web.DependencyInjection" class="">SixLabors.ImageSharp.Web.DependencyInjection</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.ApplicationBuilderExtensions.html" title="ApplicationBuilderExtensions" class="">ApplicationBuilderExtensions</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.IImageSharpBuilder.html" title="IImageSharpBuilder" class="">IImageSharpBuilder</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.ImageSharpBuilderExtensions.html" title="ImageSharpBuilderExtensions" class="">ImageSharpBuilderExtensions</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.ImageSharpConfiguration.html" title="ImageSharpConfiguration" class="">ImageSharpConfiguration</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.DependencyInjection.ServiceCollectionExtensions.html" title="ServiceCollectionExtensions" class="">ServiceCollectionExtensions</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.html" title="SixLabors.ImageSharp.Web.Middleware" class="">SixLabors.ImageSharp.Web.Middleware</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="active">
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions.html" title="ConcurrentDictionaryExtensions" class="active">ConcurrentDictionaryExtensions</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.ImageCommandContext.html" title="ImageCommandContext" class="">ImageCommandContext</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.ImageProcessingContext.html" title="ImageProcessingContext" class="">ImageProcessingContext</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.ImageSharpMiddleware.html" title="ImageSharpMiddleware" class="">ImageSharpMiddleware</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Middleware.ImageSharpMiddlewareOptions.html" title="ImageSharpMiddlewareOptions" class="">ImageSharpMiddlewareOptions</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Processors.html" title="SixLabors.ImageSharp.Web.Processors" class="">SixLabors.ImageSharp.Web.Processors</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Processors.BackgroundColorWebProcessor.html" title="BackgroundColorWebProcessor" class="">BackgroundColorWebProcessor</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Processors.FormatWebProcessor.html" title="FormatWebProcessor" class="">FormatWebProcessor</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Processors.IImageWebProcessor.html" title="IImageWebProcessor" class="">IImageWebProcessor</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Processors.JpegQualityWebProcessor.html" title="JpegQualityWebProcessor" class="">JpegQualityWebProcessor</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Processors.ResizeWebProcessor.html" title="ResizeWebProcessor" class="">ResizeWebProcessor</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Providers.html" title="SixLabors.ImageSharp.Web.Providers" class="">SixLabors.ImageSharp.Web.Providers</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Providers.IImageProvider.html" title="IImageProvider" class="">IImageProvider</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Providers.PhysicalFileSystemProvider.html" title="PhysicalFileSystemProvider" class="">PhysicalFileSystemProvider</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Providers.ProcessingBehavior.html" title="ProcessingBehavior" class="">ProcessingBehavior</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Resolvers.html" title="SixLabors.ImageSharp.Web.Resolvers" class="">SixLabors.ImageSharp.Web.Resolvers</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Resolvers.IImageCacheResolver.html" title="IImageCacheResolver" class="">IImageCacheResolver</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Resolvers.IImageResolver.html" title="IImageResolver" class="">IImageResolver</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Resolvers.PhysicalFileSystemCacheResolver.html" title="PhysicalFileSystemCacheResolver" class="">PhysicalFileSystemCacheResolver</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Resolvers.PhysicalFileSystemResolver.html" title="PhysicalFileSystemResolver" class="">PhysicalFileSystemResolver</a>
|
|
</li>
|
|
</ul> </li>
|
|
<li class="">
|
|
<span class="expand-stub"></span>
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.html" title="SixLabors.ImageSharp.Web.Synchronization" class="">SixLabors.ImageSharp.Web.Synchronization</a>
|
|
|
|
<ul class="nav level2">
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.AsyncKeyLock-1.html" title="AsyncKeyLock<TKey>" class="">AsyncKeyLock<TKey></a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.AsyncKeyReaderWriterLock-1.html" title="AsyncKeyReaderWriterLock<TKey>" class="">AsyncKeyReaderWriterLock<TKey></a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.AsyncLock.html" title="AsyncLock" class="">AsyncLock</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.AsyncReaderWriterLock.html" title="AsyncReaderWriterLock" class="">AsyncReaderWriterLock</a>
|
|
</li>
|
|
<li class="">
|
|
<a href="SixLabors.ImageSharp.Web.Synchronization.RefCountedConcurrentDictionary-2.html" title="RefCountedConcurrentDictionary<TKey, TValue>" class="">RefCountedConcurrentDictionary<TKey, TValue></a>
|
|
</li>
|
|
</ul> </li>
|
|
</ul> </div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="article row grid-right">
|
|
<div class="col-md-10">
|
|
<article class="content wrap" id="_content" data-uid="SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions">
|
|
|
|
|
|
<h1 id="SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions" data-uid="SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions" class="text-break">Class ConcurrentDictionaryExtensions
|
|
</h1>
|
|
<div class="markdown level0 summary"><p>Extensions used to manage asynchronous access to the <a class="xref" href="SixLabors.ImageSharp.Web.Middleware.ImageSharpMiddleware.html">ImageSharpMiddleware</a>
|
|
<a href="https://gist.github.com/davidfowl/3dac8f7b3d141ae87abf770d5781feed">https://gist.github.com/davidfowl/3dac8f7b3d141ae87abf770d5781feed</a></p>
|
|
</div>
|
|
<div class="markdown level0 conceptual"></div>
|
|
<div class="inheritance">
|
|
<h5>Inheritance</h5>
|
|
<div class="level0"><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object">Object</a></div>
|
|
<div class="level1"><span class="xref">ConcurrentDictionaryExtensions</span></div>
|
|
</div>
|
|
<div class="inheritedMembers">
|
|
<h5>Inherited Members</h5>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object)">Object.Equals(Object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object-system-object)">Object.Equals(Object, Object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.gethashcode#system-object-gethashcode">Object.GetHashCode()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.gettype#system-object-gettype">Object.GetType()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.memberwiseclone#system-object-memberwiseclone">Object.MemberwiseClone()</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.referenceequals#system-object-referenceequals(system-object-system-object)">Object.ReferenceEquals(Object, Object)</a>
|
|
</div>
|
|
<div>
|
|
<a class="xref" href="https://docs.microsoft.com/dotnet/api/system.object.tostring#system-object-tostring">Object.ToString()</a>
|
|
</div>
|
|
</div>
|
|
<h6><strong>Namespace</strong>: <a class="xref" href="SixLabors.ImageSharp.Web.Middleware.html">SixLabors.ImageSharp.Web.Middleware</a></h6>
|
|
<h6><strong>Assembly</strong>: SixLabors.ImageSharp.Web.dll</h6>
|
|
<h5 id="SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions_syntax">Syntax</h5>
|
|
<div class="codewrapper">
|
|
<pre><code class="lang-csharp hljs">public static class ConcurrentDictionaryExtensions</code></pre>
|
|
</div>
|
|
<h3 id="methods">Methods
|
|
</h3>
|
|
<span class="small pull-right mobile-hide">
|
|
<span class="divider">|</span>
|
|
<a href="https://github.com/SixLabors/ImageSharp.Web/new/master/apiSpec/new?filename=SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions_GetOrAddAsync__2_System_Collections_Concurrent_ConcurrentDictionary___0_System_Threading_Tasks_Task___1_____0_System_Func___0_System_Threading_Tasks_Task___1___.md&value=---%0Auid%3A%20SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions.GetOrAddAsync%60%602(System.Collections.Concurrent.ConcurrentDictionary%7B%60%600%2CSystem.Threading.Tasks.Task%7B%60%601%7D%7D%2C%60%600%2CSystem.Func%7B%60%600%2CSystem.Threading.Tasks.Task%7B%60%601%7D%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
|
|
</span>
|
|
<span class="small pull-right mobile-hide">
|
|
<a href="https://github.com/SixLabors/ImageSharp.Web/blob/12780011d24ffe1a4f821d600c5bb05e8071b5e9/src/ImageSharp.Web/Middleware/ConcurrentDictionaryExtensions.cs/#L27">View Source</a>
|
|
</span>
|
|
<a id="SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions_GetOrAddAsync_" data-uid="SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions.GetOrAddAsync*"></a>
|
|
<h4 id="SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions_GetOrAddAsync__2_System_Collections_Concurrent_ConcurrentDictionary___0_System_Threading_Tasks_Task___1_____0_System_Func___0_System_Threading_Tasks_Task___1___" data-uid="SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions.GetOrAddAsync``2(System.Collections.Concurrent.ConcurrentDictionary{``0,System.Threading.Tasks.Task{``1}},``0,System.Func{``0,System.Threading.Tasks.Task{``1}})">GetOrAddAsync<TKey, TValue>(ConcurrentDictionary<TKey, Task<TValue>>, TKey, Func<TKey, Task<TValue>>)</h4>
|
|
<div class="markdown level1 summary"><p>Provides an alternative to <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.concurrent.concurrentdictionary-2.getoradd#system-collections-concurrent-concurrentdictionary-2-getoradd(-0-system-func((-0-1)))">GetOrAdd(TKey, Func<TKey,TValue>)</a> specifically for asynchronous values. The factory method will only run once.</p>
|
|
</div>
|
|
<div class="markdown level1 conceptual"></div>
|
|
<h5 class="decalaration">Declaration</h5>
|
|
<div class="codewrapper">
|
|
<pre><code class="lang-csharp hljs">public static async Task<TValue> GetOrAddAsync<TKey, TValue>(this ConcurrentDictionary<TKey, Task<TValue>> dictionary, TKey key, Func<TKey, Task<TValue>> valueFactory)</code></pre>
|
|
</div>
|
|
<h5 class="parameters">Parameters</h5>
|
|
<table class="table table-bordered table-striped table-condensed">
|
|
<thead>
|
|
<tr>
|
|
<th>Type</th>
|
|
<th>Name</th>
|
|
<th>Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.concurrent.concurrentdictionary-2">ConcurrentDictionary</a><TKey, <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task-1">Task</a><TValue>></td>
|
|
<td><span class="parametername">dictionary</span></td>
|
|
<td><p>The <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.collections.concurrent.concurrentdictionary-2">ConcurrentDictionary<TKey,TValue></a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td><span class="xref">TKey</span></td>
|
|
<td><span class="parametername">key</span></td>
|
|
<td><p>The key of the element to add.</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.func-2">Func</a><TKey, <a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task-1">Task</a><TValue>></td>
|
|
<td><span class="parametername">valueFactory</span></td>
|
|
<td><p>The function used to generate a value for the key</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<h5 class="returns">Returns</h5>
|
|
<table class="table table-bordered table-striped table-condensed">
|
|
<thead>
|
|
<tr>
|
|
<th>Type</th>
|
|
<th>Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td><a class="xref" href="https://docs.microsoft.com/dotnet/api/system.threading.tasks.task-1">Task</a><TValue></td>
|
|
<td><p>The value for the key. This will be either the existing value for the key if the
|
|
key is already in the dictionary, or the new value for the key as returned by valueFactory
|
|
if the key was not in the dictionary.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<h5 class="typeParameters">Type Parameters</h5>
|
|
<table class="table table-bordered table-striped table-condensed">
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Description</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td><span class="parametername">TKey</span></td>
|
|
<td><p>The type of the key.</p>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td><span class="parametername">TValue</span></td>
|
|
<td><p>The value for the dictionary.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</article>
|
|
</div>
|
|
|
|
<div class="hidden-sm col-md-2" role="complementary">
|
|
<div class="sideaffix">
|
|
<div class="contribution">
|
|
<ul class="nav">
|
|
<li>
|
|
<a href="https://github.com/SixLabors/ImageSharp.Web/new/master/apiSpec/new?filename=SixLabors_ImageSharp_Web_Middleware_ConcurrentDictionaryExtensions.md&value=---%0Auid%3A%20SixLabors.ImageSharp.Web.Middleware.ConcurrentDictionaryExtensions%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A" class="contribution-link">Improve this Doc</a>
|
|
</li>
|
|
<li>
|
|
<a href="https://github.com/SixLabors/ImageSharp.Web/blob/12780011d24ffe1a4f821d600c5bb05e8071b5e9/src/ImageSharp.Web/Middleware/ConcurrentDictionaryExtensions.cs/#L14" class="contribution-link">View Source</a>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
|
|
<h5>In This Article</h5>
|
|
<div></div>
|
|
</nav>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<footer>
|
|
<div class="grad-bottom"></div>
|
|
<div class="footer">
|
|
<div class="container">
|
|
<span class="pull-right">
|
|
<a href="#top">Back to top</a>
|
|
</span>
|
|
|
|
<span>Generated by <strong>DocFX</strong></span>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
</div>
|
|
|
|
<script type="text/javascript" src="../../styles/docfx.vendor.js"></script>
|
|
<script type="text/javascript" src="../../styles/docfx.js"></script>
|
|
<script type="text/javascript" src="../../styles/main.js"></script>
|
|
</body>
|
|
</html>
|