# ResourceBuilders.AndroidLottieResourceByResId

Artifact: [androidx.wear.protolayout:protolayout](https://developer.android.com/jetpack/androidx/releases/wear-protolayout) [View Source](https://cs.android.com/search?q=file:androidx/wear/protolayout/ResourceBuilders.java+class:androidx.wear.protolayout.ResourceBuilders.AndroidLottieResourceByResId) Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.3.0)

*** ** * ** ***


```
@RequiresSchemaVersion(major = 1, minor = 500)
public final class ResourceBuilders.AndroidLottieResourceByResId
```

<br />

*** ** * ** ***

A Lottie resource that is read from a raw Android resource ID.

## Summary

| ### Nested types |
|---|
| `public final class https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId.Builder` Builder for `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId` |

| ### Public methods |
|---|---|
| `boolean` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#equals(java.lang.Object)(@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/java/lang/Object.html obj)` |
| `static int` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#getMaxPropertiesCount()()` Returns how many properties can be added for customization of one Lottie animation via `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId.Builder#setProperties(androidx.wear.protolayout.ResourceBuilders.LottieProperty...)` method. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/wear/protolayout/expression/DynamicBuilders.DynamicFloat` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#getProgress()()` Gets a `https://developer.android.com/reference/androidx/wear/protolayout/expression/DynamicBuilders.DynamicFloat`, normally transformed from certain states with the data binding pipeline to control the progress of the animation. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/util/List.html<https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.LottieProperty>` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#getProperties()()` Gets the collection of properties to customize Lottie further. |
| `int` | `@https://developer.android.com/reference/androidx/annotation/RawRes https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#getRawResourceId()()` Gets the Android resource ID, e.g. R.raw.foo. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/wear/protolayout/TriggerBuilders.Trigger` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#getStartTrigger()()` Gets the trigger to start the animation. |
| `int` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#hashCode()()` |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId#toString()()` |

## Public methods

### equals

```
public boolean equals(@Nullable Object obj)
```

### getMaxPropertiesCount

Added in [1.4.2](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.4.2)

```
public static int getMaxPropertiesCount()
```

Returns how many properties can be added for customization of one Lottie animation via `https://developer.android.com/reference/androidx/wear/protolayout/ResourceBuilders.AndroidLottieResourceByResId.Builder#setProperties(androidx.wear.protolayout.ResourceBuilders.LottieProperty...)` method.

### getProgress

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.3.0)

```
public @Nullable DynamicBuilders.DynamicFloat getProgress()
```

Gets a `https://developer.android.com/reference/androidx/wear/protolayout/expression/DynamicBuilders.DynamicFloat`, normally transformed from certain states with the data binding pipeline to control the progress of the animation.

### getProperties

Added in [1.4.2](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.4.2)

```
public @NonNull List<ResourceBuilders.LottieProperty> getProperties()
```

Gets the collection of properties to customize Lottie further.

There shouldn't be more than 10 of properties in this collection. Each property can be applied to one or more elements in Lottie file.

### getRawResourceId

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.3.0)

```
@RawRes
public int getRawResourceId()
```

Gets the Android resource ID, e.g. R.raw.foo.

### getStartTrigger

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/wear-protolayout#1.3.0)

```
public @Nullable TriggerBuilders.Trigger getStartTrigger()
```

Gets the trigger to start the animation.

### hashCode

```
public int hashCode()
```

### toString

```
public @NonNull String toString()
```