as

Settings
Sign out
Notifications
Alexa
亚马逊应用商店
AWS
文档
Support
Contact Us
My Cases
新手入门
设计和开发
应用发布
参考
支持

ContentInteractionBuilder

ContentInteractionBuilder

用于创建ContentInteraction对象的构建器。

构造函数

new ContentInteractionBuilder()

new ContentInteractionBuilder(): ContentInteractionBuilder

返回值

ContentInteractionBuilder

方法

build()

build(): ContentInteraction

使用在构建器上设置的字段构建ContentInteraction对象。

返回值

ContentInteraction

创建的ContentInteraction对象。

抛出

如果未设置必填字段,则会引发InvalidArgumentError


contentId()

contentId(contentId): ContentInteractionBuilder

设置在其上进行交互的内容的ID,可在亚马逊目录中解析该ID。这是必填字段。如果未设置此字段,build() 将失败。

参数

contentId

IContentId

可在亚马逊目录中解析的ID。

返回值

ContentInteractionBuilder

当前ContentInteractionBuilder对象。


contentInteractionType()

contentInteractionType(contentInteractionType): ContentInteractionBuilder

设置内容交互的类型。这是必填字段。如果未设置此字段,build() 将失败。

参数

contentInteractionType

ContentInteractionType

内容交互的类型。

返回值

ContentInteractionBuilder

当前ContentInteractionBuilder对象。


interactionTimestamp()

interactionTimestamp(interactionTimestamp): ContentInteractionBuilder

设置交互发生的日期。

参数

interactionTimestamp

Date

交互日期。

返回值

ContentInteractionBuilder

当前ContentInteractionBuilder对象。


profileId()

profileId(profileId): ContentInteractionBuilder

设置执行交互的用户的关联profileId

参数

profileId

IProfileId

用户关联的profileId

返回值

ContentInteractionBuilder

当前ContentInteractionBuilder对象。


Last updated: 2025年10月2日