RequestBuilders.ResourcesRequest

public final class RequestBuilders.ResourcesRequest


Parameters passed to a androidx.wear.tiles.TileBuilders.Tile service when the renderer is requesting a specific resource version.

Summary

Public constructors

Public methods

@Nullable DeviceParametersBuilders.DeviceParameters

Gets parameters describing the device requesting the resources.

@NonNull List<String>

Gets requested resource IDs.

@NonNull String

Gets the version of the resources being fetched.

Public constructors

ResourcesRequest

public final ResourcesRequest()

Public methods

getDeviceParameters

public @Nullable DeviceParametersBuilders.DeviceParameters getDeviceParameters()

Gets parameters describing the device requesting the resources. Intended for testing purposes only.

getResourceIds

public @NonNull List<StringgetResourceIds()

Gets requested resource IDs. This specifies which tile resources should be returned in the androidx.wear.tiles.ResourceBuilders.Resources response. If not specified, all resources for the given version must be provided in the response.

Note that resource IDs here correspond to tile resources (i.e. keys that would be used in androidx.wear.tiles.ResourceBuilders.Resources.idToImage), not Android resource names or similar.

getVersion

public @NonNull String getVersion()

Gets the version of the resources being fetched. This is the same as the requested resource version, passed in androidx.wear.tiles.TileBuilders.Tile.