Home
last modified time | relevance | path

Searched refs:ConsentParcel (Results 1 – 15 of 15) sorted by relevance

/packages/modules/AdServices/adservices/tests/unittest/system-service/src/com/android/server/adservices/consent/
DConsentManagerTest.java31 import android.app.adservices.consent.ConsentParcel;
111 assertThat(consentManager.getConsent(ConsentParcel.ALL_API).isIsGiven()).isFalse(); in testGetConsent_unSet()
112 assertThat(consentManager.getConsent(ConsentParcel.TOPICS).isIsGiven()).isFalse(); in testGetConsent_unSet()
113 assertThat(consentManager.getConsent(ConsentParcel.FLEDGE).isIsGiven()).isFalse(); in testGetConsent_unSet()
114 assertThat(consentManager.getConsent(ConsentParcel.MEASUREMENT).isIsGiven()).isFalse(); in testGetConsent_unSet()
123 new ConsentParcel.Builder() in testGetAndSetConsent_null()
124 .setConsentApiType(ConsentParcel.ALL_API) in testGetAndSetConsent_null()
128 assertThat(consentManager.getConsent(ConsentParcel.ALL_API).isIsGiven()).isFalse(); in testGetAndSetConsent_null()
131 new ConsentParcel.Builder() in testGetAndSetConsent_null()
132 .setConsentApiType(ConsentParcel.TOPICS) in testGetAndSetConsent_null()
[all …]
/packages/modules/AdServices/adservices/framework/java/android/app/adservices/consent/
DConsentParcel.java32 public final class ConsentParcel implements Parcelable { class
60 private ConsentParcel(@NonNull Builder builder) { in ConsentParcel() method in ConsentParcel
65 private ConsentParcel(@NonNull Parcel in) { in ConsentParcel() method in ConsentParcel
70 public static final @NonNull Creator<ConsentParcel> CREATOR =
71 new Parcelable.Creator<ConsentParcel>() {
73 public ConsentParcel createFromParcel(Parcel in) {
74 return new ConsentParcel(in);
78 public ConsentParcel[] newArray(int size) {
79 return new ConsentParcel[size];
106 public static ConsentParcel createRevokedConsent(@ConsentApiType int consentApiType) { in createRevokedConsent()
[all …]
DConsentParcel.aidl19 parcelable ConsentParcel;
/packages/modules/AdServices/adservices/tests/unittest/framework/src/android/app/adservices/consent/
DConsentParcelTest.java19 import static android.app.adservices.consent.ConsentParcel.ALL_API;
20 import static android.app.adservices.consent.ConsentParcel.FLEDGE;
21 import static android.app.adservices.consent.ConsentParcel.MEASUREMENT;
22 import static android.app.adservices.consent.ConsentParcel.TOPICS;
35 ConsentParcel consentParcel = in testConsentParcel()
36 new ConsentParcel.Builder().setConsentApiType(ALL_API).setIsGiven(true).build(); in testConsentParcel()
41 new ConsentParcel.Builder().setConsentApiType(TOPICS).setIsGiven(false).build(); in testConsentParcel()
46 new ConsentParcel.Builder().setConsentApiType(FLEDGE).setIsGiven(false).build(); in testConsentParcel()
51 new ConsentParcel.Builder().setConsentApiType(MEASUREMENT).setIsGiven(true).build(); in testConsentParcel()
61 new ConsentParcel.Builder() in testConsentParcel_notSetConsentApiType()
/packages/modules/AdServices/adservices/tests/unittest/ui/src/com/android/adservices/service/consent/
DAdServicesStorageManagerTest.java35 import android.app.adservices.consent.ConsentParcel;
114 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testGetKnownAppsWithConsent()
116 .getConsent(ConsentParcel.ALL_API); in testGetKnownAppsWithConsent()
158 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testIsFledgeConsentRevokedForAppAfterSetFledgeUseWithFullApiConsent()
160 .getConsent(ConsentParcel.ALL_API); in testIsFledgeConsentRevokedForAppAfterSetFledgeUseWithFullApiConsent()
204 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxDisabled()
206 .getConsent(ConsentParcel.ALL_API); in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxDisabled()
244 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.FLEDGE)) in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxEnabled()
246 .getConsent(ConsentParcel.FLEDGE); in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxEnabled()
284 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testIsFledgeConsentRevokedForNotFoundAppGaUxDisabledThrows()
[all …]
DConsentManagerTest.java96 import android.app.adservices.consent.ConsentParcel;
422 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testConsentManager_LazyEnable()
424 .getConsent(ConsentParcel.ALL_API); in testConsentManager_LazyEnable()
440 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testConsentManager_LazyDisabled()
442 .getConsent(ConsentParcel.ALL_API); in testConsentManager_LazyDisabled()
457 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.MEASUREMENT)) in testConsentManagerPreApi_LazyEnable()
459 .getConsent(ConsentParcel.MEASUREMENT); in testConsentManagerPreApi_LazyEnable()
481 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.MEASUREMENT)) in testConsentManagerPreApi_LazyDisabled()
483 .getConsent(ConsentParcel.MEASUREMENT); in testConsentManagerPreApi_LazyDisabled()
975 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.FLEDGE)) in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxEnabled_systemServerOnly()
[all …]
DConsentManagerV2Test.java91 import android.app.adservices.consent.ConsentParcel;
439 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testConsentManager_LazyEnable()
441 .getConsent(ConsentParcel.ALL_API); in testConsentManager_LazyEnable()
457 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.ALL_API)) in testConsentManager_LazyDisabled()
459 .getConsent(ConsentParcel.ALL_API); in testConsentManager_LazyDisabled()
474 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.MEASUREMENT)) in testConsentManagerPreApi_LazyEnable()
476 .getConsent(ConsentParcel.MEASUREMENT); in testConsentManagerPreApi_LazyEnable()
493 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.MEASUREMENT)) in testConsentManagerPreApi_LazyDisabled()
495 .getConsent(ConsentParcel.MEASUREMENT); in testConsentManagerPreApi_LazyDisabled()
922 doReturn(ConsentParcel.createGivenConsent(ConsentParcel.FLEDGE)) in testIsFledgeConsentRevokedForAppWithFullApiConsentGaUxEnabled_systemServerOnly()
[all …]
/packages/modules/AdServices/adservices/tests/unittest/system-service/src/com/android/server/adservices/
DAdServicesManagerServiceTest.java40 import android.app.adservices.consent.ConsentParcel;
479 assertThat(service.getConsent(ConsentParcel.ALL_API).isIsGiven()).isFalse(); in testGetConsent_unSet()
480 assertThat(service.getConsent(ConsentParcel.TOPICS).isIsGiven()).isFalse(); in testGetConsent_unSet()
481 assertThat(service.getConsent(ConsentParcel.FLEDGE).isIsGiven()).isFalse(); in testGetConsent_unSet()
482 assertThat(service.getConsent(ConsentParcel.MEASUREMENT).isIsGiven()).isFalse(); in testGetConsent_unSet()
493 new ConsentParcel.Builder() in testGetAndSetConsent_null()
494 .setConsentApiType(ConsentParcel.ALL_API) in testGetAndSetConsent_null()
498 assertThat(service.getConsent(ConsentParcel.ALL_API).isIsGiven()).isFalse(); in testGetAndSetConsent_null()
501 new ConsentParcel.Builder() in testGetAndSetConsent_null()
502 .setConsentApiType(ConsentParcel.TOPICS) in testGetAndSetConsent_null()
[all …]
/packages/modules/AdServices/adservices/service/java/com/android/server/adservices/consent/
DConsentManager.java19 import android.app.adservices.consent.ConsentParcel;
138 public ConsentParcel getConsent(@ConsentParcel.ConsentApiType int consentApiType) { in getConsent()
143 return new ConsentParcel.Builder() in getConsent()
149 return ConsentParcel.createRevokedConsent(consentApiType); in getConsent()
156 public void setConsent(ConsentParcel consentParcel) throws IOException { in setConsent()
162 if (consentParcel.getConsentApiType() == ConsentParcel.ALL_API) { in setConsent()
165 getConsentApiTypeKey(ConsentParcel.TOPICS), consentParcel.isIsGiven()); in setConsent()
167 getConsentApiTypeKey(ConsentParcel.FLEDGE), consentParcel.isIsGiven()); in setConsent()
169 getConsentApiTypeKey(ConsentParcel.MEASUREMENT), consentParcel.isIsGiven()); in setConsent()
173 getConsentApiTypeKey(ConsentParcel.TOPICS), /* defaultValue */ in setConsent()
[all …]
/packages/modules/AdServices/adservices/service-core/java/com/android/adservices/service/consent/
DAdServicesApiType.java19 import android.app.adservices.consent.ConsentParcel;
44 return ConsentParcel.TOPICS; in toConsentApiType()
46 return ConsentParcel.FLEDGE; in toConsentApiType()
48 return ConsentParcel.MEASUREMENT; in toConsentApiType()
50 return ConsentParcel.ALL_API; in toConsentApiType()
52 return ConsentParcel.UNKNOWN; in toConsentApiType()
DAdServicesStorageManager.java25 import android.app.adservices.consent.ConsentParcel;
128 ConsentParcel consentParcel = mAdServicesManager.getConsent(consentApiType); in getConsent()
289 ConsentParcel consentParcel = in setConsent()
290 new ConsentParcel.Builder() in setConsent()
DConsentManager.java38 import android.app.adservices.consent.ConsentParcel;
490 mAdServicesManager.getConsent(ConsentParcel.ALL_API).isIsGiven()), in getConsent()
1741 ConsentParcel consentParcel =
1742 new ConsentParcel.Builder()
1743 .setConsentApiType(ConsentParcel.ALL_API)
1751 @ConsentParcel.ConsentApiType int consentApiType,
1756 adServicesManager.setConsent(ConsentParcel.createGivenConsent(consentApiType));
1758 adServicesManager.setConsent(ConsentParcel.createRevokedConsent(consentApiType));
1765 @ConsentParcel.ConsentApiType int consentApiType) {
1773 return getPerApiConsentFromSystemServer(adServicesManager, ConsentParcel.ALL_API);
[all …]
/packages/modules/AdServices/adservices/framework/java/android/app/adservices/
DIAdServicesManager.aidl19 import android.app.adservices.consent.ConsentParcel;
31 ConsentParcel getConsent(in int consentApiType); in getConsent()
36 void setConsent(in ConsentParcel consentParcel); in setConsent()
DAdServicesManager.java25 import android.app.adservices.consent.ConsentParcel;
93 public ConsentParcel getConsent(@ConsentParcel.ConsentApiType int consentApiType) { in getConsent()
103 public void setConsent(@NonNull ConsentParcel consentParcel) { in setConsent()
/packages/modules/AdServices/adservices/service/java/com/android/server/adservices/
DAdServicesManagerService.java26 import android.app.adservices.consent.ConsentParcel;
234 public ConsentParcel getConsent(@ConsentParcel.ConsentApiType int consentApiType) { in getConsent()
236 ConsentParcel.createRevokedConsent(consentApiType), in getConsent()
249 public void setConsent(ConsentParcel consentParcel) { in setConsent()