Summary:
Methods
| Inherited Methods
TopicsManager
public
final
class
TopicsManager
extends Object
| java.lang.Object | |
| ↳ | android.adservices.topics.TopicsManager |
TopicsManager provides APIs for App and Ad-Sdks to get the user interest topics in a privacy preserving way.
The instance of the TopicsManager can be obtained using Context.getSystemService(Class and TopicsManager class.
Summary
Public methods | |
|---|---|
void
|
getTopics(GetTopicsRequest getTopicsRequest, Executor executor, OutcomeReceiver<GetTopicsResponse, Exception> callback)
Return the topics. |
Inherited methods | |
|---|---|
Public methods
getTopics
public void getTopics (GetTopicsRequest getTopicsRequest, Executor executor, OutcomeReceiver<GetTopicsResponse, Exception> callback)
Return the topics.
Requires AdServicesPermissions.ACCESS_ADSERVICES_TOPICS
| Parameters | |
|---|---|
getTopicsRequest |
GetTopicsRequest: The request for obtaining Topics.
This value cannot be null. |
executor |
Executor: The executor to run callback.
This value cannot be null.
Callback and listener events are dispatched through this
Executor, providing an easy way to control which thread is
used. To dispatch events through the main thread of your
application, you can use
Context.getMainExecutor().
Otherwise, provide an Executor that dispatches to an appropriate thread. |
callback |
OutcomeReceiver: The callback that's called after topics are available or an error occurs.
This value cannot be null. |
| Returns | |
|---|---|
void |
This value cannot be null. |
| Throws | |
|---|---|
SecurityException |
if caller is not authorized to call this API. |
IllegalStateException |
if this API is not available. |
LimitExceededException |
if rate limit was reached. |