# Codec_LegacyGrainId

Package: [Microsoft.Orleans.Core.Abstractions](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/) 10.0.0

[NuGet package](https://www.nuget.org/packages/Microsoft.Orleans.Core.Abstractions)

```csharp
public sealed class Codec_LegacyGrainId : IFieldCodec, IFieldCodec<LegacyGrainId>
```

Supports all classes in the .NET class hierarchy and provides low-level services to derived classes. This is the ultimate base class of all .NET classes; it is the root of the type hierarchy.

## Constructors

- [Codec_LegacyGrainId(IActivator&lt;LegacyGrainId&gt;, ICodecProvider)](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleanscodegen.orleans.runtime.codec-legacygrainid/constructors/constructor-orleans-serialization-activators-iactivator-orleans-runtime-legacygr-a433f693/)

## Methods

- [Deserialize(Reader&lt;TReaderInput&gt;, LegacyGrainId)](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleanscodegen.orleans.runtime.codec-legacygrainid/methods/deserialize-1-ref-orleans-serialization-buffers-reader-treaderinput-orleans-runt-5febde6d/)
- [ReadValue(Reader&lt;TReaderInput&gt;, Field)](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleanscodegen.orleans.runtime.codec-legacygrainid/methods/readvalue-1-ref-orleans-serialization-buffers-reader-treaderinput-orleans-serial-d7713b00/)
- [Serialize(Writer&lt;TBufferWriter&gt;, LegacyGrainId)](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleanscodegen.orleans.runtime.codec-legacygrainid/methods/serialize-1-ref-orleans-serialization-buffers-writer-tbufferwriter-orleans-runti-132803c4/)
- [WriteField(Writer&lt;TBufferWriter&gt;, uint, Type, LegacyGrainId)](/orleans/docs/api/csharp/microsoft.orleans.core.abstractions/orleanscodegen.orleans.runtime.codec-legacygrainid/methods/writefield-1-ref-orleans-serialization-buffers-writer-tbufferwriter-uint-system-26f6575e/)
