# NativeParallelHashMap<TKey, TValue>.Enumerator

> An enumerator over the key-value pairs of a hash map.

## Definition

* **Type:** Struct
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule
* **Implements:** [IEnumerator\<KeyValue\<T, T>>](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerator-1), [IEnumerator](https://learn.microsoft.com/dotnet/api/system.collections.ienumerator), [IDisposable](https://learn.microsoft.com/dotnet/api/system.idisposable)

```csharp
public struct NativeParallelHashMap<TKey, TValue>.Enumerator : IEnumerator<KeyValue<TKey, TValue>>, IEnumerator, IDisposable
```

## Remarks

In an enumerator's initial state, [NativeParallelHashMap\<TKey, TValue>.Enumerator.Current](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/current.md) is not valid to read. From this state, the first [NativeParallelHashMap\<TKey, TValue>.Enumerator.MoveNext](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/movenext.md) call advances the enumerator to the first key-value pair.

## Properties

| Property                                                                                                  | Description                 |
| --------------------------------------------------------------------------------------------------------- | --------------------------- |
| [Current](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/current.md) | The current key-value pair. |

## Methods

| Method                                                                                                      | Description                                         |
| ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------- |
| [Dispose](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/dispose.md)   | Does nothing.                                       |
| [MoveNext](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/movenext.md) | Advances the enumerator to the next key-value pair. |
| [Reset](/engine/6000.7/script-reference/unity/collections/nativeparallelhashmap2/enumerator/reset.md)       | Resets the enumerator to its initial state.         |
