ColorBuilders.ColorStop.Builder


public final class ColorBuilders.ColorStop.Builder


Builder for ColorStop

Summary

Public constructors

@RequiresSchemaVersion(major = 1, minor = 300)
Builder(
    @NonNull ColorBuilders.ColorProp color,
    @NonNull TypeBuilders.FloatProp offset
)

Creates an instance of Builder.

Public methods

@NonNull ColorBuilders.ColorStop

Builds an instance from accumulated values.

Public constructors

Builder

Added in 1.1.0
@RequiresSchemaVersion(major = 1, minor = 300)
public Builder(
    @NonNull ColorBuilders.ColorProp color,
    @NonNull TypeBuilders.FloatProp offset
)

Creates an instance of Builder.

Parameters
@NonNull ColorBuilders.ColorProp color

the color for this stop. Only opaque colors are supported. Any transparent colors will have their alpha component set to 0xFF (opaque). Note that this parameter only supports static values.

@NonNull TypeBuilders.FloatProp offset

the relative offset for this color, between 0 and 1. This determines where the color is positioned relative to a gradient space. Note that this parameter only supports static values.

Public methods

build

Added in 1.1.0
public @NonNull ColorBuilders.ColorStop build()

Builds an instance from accumulated values.