# Interface IDeepCloneable&lt;T&gt; (3.27.1)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [3.27.1 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1)
- [3.23.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/3.23.0/Google.Protobuf.IDeepCloneable-1)
- [3.15.8](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/3.15.8/Google.Protobuf.IDeepCloneable-1)

    public interface IDeepCloneable<T>

Generic interface for a deeply cloneable type.

## Namespace

[Google.Protobuf](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf)

## Assembly

Google.Protobuf.dll

| ## Type Parameter ||
|---|---|
| **Name** | **Description** |
| `T` | The type itself, returned by the [Clone()](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1#Google_Protobuf_IDeepCloneable_1_Clone) method. |

## Remarks


All generated messages implement this interface, but so do some non-message types.
Additionally, due to the type constraint on `T` in [IMessage\<T\>](https://docs.cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1),
it is simpler to keep this as a separate interface.

## Methods

### Clone()

    T Clone()

Creates a deep clone of this object.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `T` | A deep clone of this object. |