/cts/tests/tests/content/src/android/content/cts/ |
D | ActivityRequireContentUriPermissionFromCallerTest.java | 176 @TestParameter({"NONE", "READ", "WRITE", "READ_AND_WRITE"}) ModeFlags modeFlags, in testNoneAttribute_allModeFlags_doNotThrow() argument 179 modeFlags, uriLocation); 187 @TestParameter({"READ", "READ_AND_WRITE"}) ModeFlags modeFlags, in testReadAttribute_readModeFlags_doNotThrow() argument 190 modeFlags, uriLocation); 198 @TestParameter({"NONE", "WRITE"}) ModeFlags modeFlags, in testReadAttribute_noneAndWriteModeFlags_throw() argument 201 modeFlags, uriLocation); 209 @TestParameter({"WRITE", "READ_AND_WRITE"}) ModeFlags modeFlags, in testWriteAttribute_writeModeFlags_doNotThrow() argument 212 modeFlags, uriLocation); 220 @TestParameter({"NONE", "READ"}) ModeFlags modeFlags, in testWriteAttribute_noneAndReadModeFlags_throw() argument 223 modeFlags, uriLocation); [all …]
|
D | MockContentProvider.java | 450 public int checkUriPermission(@NonNull Uri uri, int uid, @Intent.AccessUriMode int modeFlags) { in checkUriPermission() argument 451 if ((modeFlags & Intent.FLAG_GRANT_READ_URI_PERMISSION) != 0) { in checkUriPermission()
|
/cts/tests/tests/content/ContentUriTestApp/src/android/content/cts/contenturitestapp/ |
D | TestService.java | 35 public Uri getContentUriForContext(int pkgAccessType, int modeFlags) { 39 case PKG_ACCESS_TYPE_GENERAL -> TestProvider.getSubsetContentUri(modeFlags); 45 if (pkgAccessType == PKG_ACCESS_TYPE_GRANT && modeFlags != 0) { 46 grantUriPermission(RECIPIENT, uri, modeFlags);
|
D | TestProvider.java | 43 public static Uri getSubsetContentUri(int modeFlags) { in getSubsetContentUri() argument 44 boolean hasRead = (modeFlags & Intent.FLAG_GRANT_READ_URI_PERMISSION) != 0; in getSubsetContentUri() 45 boolean hasWrite = (modeFlags & Intent.FLAG_GRANT_WRITE_URI_PERMISSION) != 0; in getSubsetContentUri()
|
D | IContentUriTestService.aidl | 38 Uri getContentUriForContext(int pkgAccessType, int modeFlags); in getContentUriForContext() argument
|
/cts/tests/tests/app/test-apps/TestComponentCallerApp/src/android/app/cts/testcomponentcaller/ |
D | TestInitialCallerActivity.java | 64 int modeFlags = intent.getIntExtra(MODE_FLAGS_TO_CHECK, -1); in performTest() local 69 startTestActivity(getUriToCheck(uriLocationId, intent), modeFlags, isNewIntent); in performTest() local 71 sendTestBroadcast(getUriToCheck(uriLocationId, intent), modeFlags, caller, in performTest() local 83 private void startTestActivity(Uri uri, int modeFlags, boolean isNewIntent) { in startTestActivity() argument 87 intent.putExtra(MODE_FLAGS_TO_CHECK, modeFlags); in startTestActivity() 90 Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK | modeFlags); in startTestActivity() 97 private void sendTestBroadcast(Uri uri, int modeFlags, ComponentCaller caller, in sendTestBroadcast() argument 105 permissionResult = caller.checkContentUriPermission(uri, modeFlags); in sendTestBroadcast()
|
/cts/tests/tests/app/src/android/app/cts/ |
D | ComponentCallerTest.java | 1686 private String modeFlagsToString(ModeFlags modeFlags) { in modeFlagsToString() argument 1687 return switch (modeFlags.mValue) { in modeFlagsToString() 1772 int modeFlags = intent.getIntExtra(MODE_FLAGS_TO_CHECK, -1); in performTest() local 1777 modeFlags); in performTest() 1920 int modeFlags = resultIntent.getIntExtra(PUT_MODE_FLAGS, -1); in buildResultIntent() local 1921 resultIntent.putExtra(MODE_FLAGS_TO_CHECK, modeFlags); in buildResultIntent() 1924 int modeFlags = resultIntent.getIntExtra(GRANT_MODE_FLAGS, 0); in buildResultIntent() local 1925 resultIntent.addFlags(modeFlags); in buildResultIntent()
|
/cts/tests/tests/appenumeration/lib/src/android/appenumeration/cts/ |
D | TestActivity.java | 368 final int modeFlags = intent.getFlags() & (Intent.FLAG_GRANT_WRITE_URI_PERMISSION in handleIntent() local 371 getContentResolver().takePersistableUriPermission(uri, modeFlags); in handleIntent()
|