# AnimationIterationCount

> Represents the number of times an animation repeats, used by the animation-iteration-count style property. The count is either a finite number of iterations or AnimationIterationCount.Infinite.

## Definition

* **Type:** Struct
* **Namespace:** [UnityEngine.UIElements](/engine/6000.7/script-reference/unityengine/uielements.md)
* **Assembly:** UnityEngine.UIElementsModule
* **Implements:** [IEquatable\<AnimationIterationCount>](https://learn.microsoft.com/dotnet/api/system.iequatable-1)

```csharp
public readonly struct AnimationIterationCount : IEquatable<AnimationIterationCount>
```

## Constructors

| Constructor                                                                                                                      | Description                                                                                                            |
| -------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
| [AnimationIterationCount(System.Single)](/engine/6000.7/script-reference/unityengine/uielements/animationiterationcount/ctor.md) | Creates a finite iteration count. Negative values clamp to 0 (0 is valid: the animation is applied but does not play). |

## Properties

| Property                                                                                         | Description                                                               |
| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------- |
| [value](/engine/6000.7/script-reference/unityengine/uielements/animationiterationcount/value.md) | The number of iterations. Is PositiveInfinity when the count is infinite. |

## Methods

| Method                                                                                                     | Description                            |
| ---------------------------------------------------------------------------------------------------------- | -------------------------------------- |
| [IsInfinite](/engine/6000.7/script-reference/unityengine/uielements/animationiterationcount/isinfinite.md) | Whether the animation repeats forever. |

## Static Methods

| Method                                                                                                 | Description                                 |
| ------------------------------------------------------------------------------------------------------ | ------------------------------------------- |
| [Infinite](/engine/6000.7/script-reference/unityengine/uielements/animationiterationcount/infinite.md) | A count that repeats the animation forever. |
