# ConcurrentDictionaryCodec&lt;TKey, TValue&gt;

Package: [Microsoft.Orleans.Serialization](/orleans/docs/api/csharp/microsoft.orleans.serialization/) 10.0.0

[NuGet package](https://www.nuget.org/packages/Microsoft.Orleans.Serialization) | [Source](https://github.com/dotnet/orleans/blob/e4e752cedecc2976811db49802c7a999b1f1c704/src/Orleans.Serialization/Codecs/ConcurrentDictionaryCodec.cs#L16)

```csharp
public sealed class ConcurrentDictionaryCodec<TKey, TValue> : GeneralizedReferenceTypeSurrogateCodec<ConcurrentDictionary<TKey, TValue>, ConcurrentDictionarySurrogate<TKey, TValue>>
```

Serializer for `System.Collections.Concurrent.ConcurrentDictionary-2`.

## Type parameters

- `TKey`: The type of the t key.
- `TValue`: The type of the t value.

## Constructors

- [ConcurrentDictionaryCodec&lt;TKey, TValue&gt;(IValueSerializer&lt;ConcurrentDictionarySurrogate&lt;TKey, TValue&gt;&gt;)](/orleans/docs/api/csharp/microsoft.orleans.serialization/orleans.serialization.codecs.concurrentdictionarycodec-2/constructors/constructor-orleans-serialization-serializers-ivalueserializer-orleans-serializa-83e500c4/)

## Methods

- [ConvertFromSurrogate(ConcurrentDictionarySurrogate&lt;TKey, TValue&gt;)](/orleans/docs/api/csharp/microsoft.orleans.serialization/orleans.serialization.codecs.concurrentdictionarycodec-2/methods/convertfromsurrogate-ref-orleans-serialization-codecs-concurrentdictionarysurrog-605a5b66/)
- [ConvertToSurrogate(ConcurrentDictionary&lt;TKey, TValue&gt;, ConcurrentDictionarySurrogate&lt;TKey, TValue&gt;)](/orleans/docs/api/csharp/microsoft.orleans.serialization/orleans.serialization.codecs.concurrentdictionarycodec-2/methods/converttosurrogate-system-collections-concurrent-concurrentdictionary-tkey-tvalu-674dac18/)
