ReportImpressionRequest
public class ReportImpressionRequest
extends Object
| java.lang.Object | |
| ↳ | android.adservices.adselection.ReportImpressionRequest |
表示 reportImpression API 的输入参数。
摘要
公共构造方法 | |
|---|---|
ReportImpressionRequest(long adSelectionId, AdSelectionConfig adSelectionConfig)
用于设备端广告选择报告请求的构造方法。 |
|
ReportImpressionRequest(long adSelectionId)
用于竞价服务器广告选择报告请求的构造方法。 |
|
公共方法 | |
|---|---|
AdSelectionConfig
|
getAdSelectionConfig()
返回 adSelectionConfig,它是 |
long
|
getAdSelectionId()
返回 adSelectionId,它是 |
继承的方法 | |
|---|---|
公共构造方法
ReportImpressionRequest
public ReportImpressionRequest (long adSelectionId,
AdSelectionConfig adSelectionConfig)用于设备端广告选择报告请求的构造方法。
如果您的 adSelectionId 是使用 AdSelectionManager.selectAds(android.adservices.adselection.AdSelectionConfig, java.util.concurrent.Executor, android.os.OutcomeReceiver) 运行设备端竞价获得的,则您的展示次数报告请求必须包含您的 AdSelectionConfig。
| 参数 | |
|---|---|
adSelectionId |
long:从 AdSelectionManager#selectAds(AdSelectionConfig, Executor, OutcomeReceiver) 接收 |
adSelectionConfig |
AdSelectionConfig:用于触发 AdSelectionManager.selectAds(android.adservices.adselection.AdSelectionConfig, java.util.concurrent.Executor, android.os.OutcomeReceiver) 的相同 AdSelectionConfig。此值不能为 null。 |
ReportImpressionRequest
public ReportImpressionRequest (long adSelectionId)
用于竞价服务器广告选择报告请求的构造方法。
如果您的 adSelectionId 是用于通过 AdSelectionManager#getAdSelectionData 收集设备信息的服务器竞价运行获得的,则您的展示次数报告请求应仅包含广告选择 ID。
在发出展示次数报告请求之前,必须使用服务器返回的加密结果 blob 调用 AdSelectionManager#persistAdSelectionResult。
| 参数 | |
|---|---|
adSelectionId |
long:从 AdSelectionManager#getAdSelectionData 接收 |
公共方法
getAdSelectionConfig
public AdSelectionConfig getAdSelectionConfig ()
返回 adSelectionConfig,它是 ReportImpressionRequest 的输入之一
| 返回 | |
|---|---|
AdSelectionConfig |
此值不能为 null。 |
getAdSelectionId
public long getAdSelectionId ()
返回 adSelectionId,它是 ReportImpressionRequest 的输入之一
| 返回 | |
|---|---|
long |
|