# GetKeyValue(out TKey, out TValue)

> Gets the key and the value.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections.LowLevel.Unsafe](/engine/6000.7/script-reference/unity/collections/lowlevel/unsafe.md)
* **Assembly:** UnityEngine.ManagedKernelModule

## GetKeyValue(T, T)

```csharp
public bool GetKeyValue(out TKey key, out TValue value)
```

### Parameters

**** (T): Outputs the key. If this KeyValue is Null, outputs the default of TKey.**** (T): Outputs the value. If this KeyValue is Null, outputs the default of TValue.

### Returns

| Type                                                          | Description                          |
| ------------------------------------------------------------- | ------------------------------------ |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if the key-value pair is valid. |
