ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder


public final class ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder


Builder for AndroidSeekableAnimatedImageResourceByResId

Summary

Public constructors

Creates an instance of Builder.

Public methods

@NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId

Builds an instance from accumulated values.

@NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder
@RequiresSchemaVersion(major = 1, minor = 200)
setAnimatedImageFormat(int animatedImageFormat)

Sets the format for the animated image.

@NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder

Sets a androidx.wear.protolayout.expression.DynamicBuilders.DynamicFloat, normally transformed from certain states with the data binding pipeline to control the progress of the animation.

@NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder
@RequiresSchemaVersion(major = 1, minor = 200)
setResourceId(@DrawableRes int resourceId)

Sets the Android resource ID, e.g. R.drawable.foo.

Public constructors

Builder

Added in 1.0.0
public Builder()

Creates an instance of Builder.

Public methods

build

Added in 1.0.0
public @NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId build()

Builds an instance from accumulated values.

setAnimatedImageFormat

Added in 1.0.0
@RequiresSchemaVersion(major = 1, minor = 200)
public @NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder setAnimatedImageFormat(int animatedImageFormat)

Sets the format for the animated image.

setProgress

Added in 1.0.0
@RequiresSchemaVersion(major = 1, minor = 200)
public @NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder setProgress(@NonNull DynamicBuilders.DynamicFloat progress)

Sets a androidx.wear.protolayout.expression.DynamicBuilders.DynamicFloat, normally transformed from certain states with the data binding pipeline to control the progress of the animation. Its value is required to fall in the range of [0.0, 1.0]. Any values outside this range would be clamped. When the first value of the androidx.wear.protolayout.expression.DynamicBuilders.DynamicFloat arrives, the animation starts from progress 0 to that value. After that it plays from current progress to the new value on subsequent updates. If not set, the animation will play on load (similar to a non-seekable animated).

setResourceId

Added in 1.0.0
@RequiresSchemaVersion(major = 1, minor = 200)
public @NonNull ResourceBuilders.AndroidSeekableAnimatedImageResourceByResId.Builder setResourceId(@DrawableRes int resourceId)

Sets the Android resource ID, e.g. R.drawable.foo.