ResourceBuilders.Resources


@RequiresSchemaVersion(major = 1, minor = 0)
public final class ResourceBuilders.Resources


The resources for a layout.

Summary

Nested types

Builder for Resources

Public methods

@NonNull Map<StringResourceBuilders.ImageResource>

Gets a map of resource_ids to images, which can be used by layouts.

@NonNull String

Gets the version of this Resources instance.

@NonNull String

Public methods

getIdToImageMapping

Added in 1.0.0
public @NonNull Map<StringResourceBuilders.ImageResourcegetIdToImageMapping()

Gets a map of resource_ids to images, which can be used by layouts.

getVersion

Added in 1.0.0
public @NonNull String getVersion()

Gets the version of this Resources instance.

Each layout specifies the version of resources it requires. After fetching a layout, the renderer will use the resources version specified by the layout to separately fetch the resources.

This value must match the version of the resources required by the layout for the layout to render successfully, and must match the resource version specified in ResourcesRequest which triggered this request.

toString

public @NonNull String toString()