Home
last modified time | relevance | path

Searched refs:modeFlags (Results 1 – 8 of 8) sorted by relevance

/cts/tests/tests/content/src/android/content/cts/
DActivityRequireContentUriPermissionFromCallerTest.java176 @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 …]
DMockContentProvider.java450 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/
DTestService.java35 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);
DTestProvider.java43 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()
DIContentUriTestService.aidl38 Uri getContentUriForContext(int pkgAccessType, int modeFlags); in getContentUriForContext() argument
/cts/tests/tests/app/test-apps/TestComponentCallerApp/src/android/app/cts/testcomponentcaller/
DTestInitialCallerActivity.java64 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/
DComponentCallerTest.java1686 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/
DTestActivity.java368 final int modeFlags = intent.getFlags() & (Intent.FLAG_GRANT_WRITE_URI_PERMISSION in handleIntent() local
371 getContentResolver().takePersistableUriPermission(uri, modeFlags); in handleIntent()