Added in API level 35

Builder


class Builder
kotlin.Any
   ↳ android.adservices.ondevicepersonalization.RenderOutput.Builder

A builder for RenderOutput

Summary

Public constructors

Public methods
RenderOutput

Builds the instance.

RenderOutput.Builder
setContent(value: String?)

The HTML content to be rendered in a webview.

RenderOutput.Builder

A key in the REMOTE_DATA IsolatedService#getRemoteData(RequestToken) table that points to an Apache Velocity template.

RenderOutput.Builder

The parameters to be populated in the template from getTemplateId().

Public constructors

Builder

Added in API level 35
Builder()

Public methods

build

Added in API level 35
fun build(): RenderOutput

Builds the instance. This builder should not be touched after calling this!

Return
RenderOutput This value cannot be null.

setContent

Added in API level 35
fun setContent(value: String?): RenderOutput.Builder

The HTML content to be rendered in a webview. If this is null, the ODP service generates HTML from the data in getTemplateId() and getTemplateParams() as described below.

Parameters
value String?: This value may be null.

setTemplateId

Added in API level 35
fun setTemplateId(value: String?): RenderOutput.Builder

A key in the REMOTE_DATA IsolatedService#getRemoteData(RequestToken) table that points to an Apache Velocity template. This is ignored if getContent() is not null.

Parameters
value String?: This value may be null.

setTemplateParams

Added in API level 35
fun setTemplateParams(value: PersistableBundle): RenderOutput.Builder

The parameters to be populated in the template from getTemplateId(). This is ignored if getContent() is not null.

Parameters
value PersistableBundle: This value cannot be null.