HomeSort by relevance Sort by last modified time
    Searched refs:mContentResolver (Results 1 - 25 of 35) sorted by null

1 2

  /cts/tests/tests/provider/src/android/provider/cts/
Contacts_SettingsTest.java 24 private ContentResolver mContentResolver;
29 mContentResolver = getInstrumentation().getTargetContext().getContentResolver();
37 Settings.setSetting(mContentResolver, "account", key1, value1);
38 Settings.setSetting(mContentResolver, "account", key2, value2);
39 assertEquals(value1, Settings.getSetting(mContentResolver, "account", key1));
40 assertEquals(value2, Settings.getSetting(mContentResolver, "account", key2));
41 assertNull(Settings.getSetting(mContentResolver, "account", "key not exist"));
43 Settings.setSetting(mContentResolver, "account", key1, value2);
44 assertEquals(value2, Settings.getSetting(mContentResolver, "account", key1));
MediaStore_Audio_GenresTest.java 32 private ContentResolver mContentResolver;
38 mContentResolver = getInstrumentation().getContext().getContentResolver();
43 assertNotNull(c = mContentResolver.query(
48 assertNotNull(c = mContentResolver.query(
59 assertNull(mContentResolver.query(Genres.getContentUri(volume), null, null, null, null));
66 Uri uri = mContentResolver.insert(Genres.EXTERNAL_CONTENT_URI, values);
71 Cursor c = mContentResolver.query(uri, null, null, null, null);
81 assertEquals(1, mContentResolver.update(uri, values, null, null));
82 c = mContentResolver.query(uri, null, null, null, null);
87 assertEquals(1, mContentResolver.delete(uri, null, null))
    [all...]
MediaStoreTest.java 35 private ContentResolver mContentResolver;
40 mContentResolver = getInstrumentation().getContext().getContentResolver();
41 Cursor c = mContentResolver.query(mScannerUri, PROJECTION, null, null, null);
55 mContentResolver.insert(mScannerUri, values);
67 assertNull(mContentResolver.query(mScannerUri, PROJECTION,
73 mContentResolver.insert(mScannerUri, values));
76 Cursor c = mContentResolver.query(mScannerUri, PROJECTION,
84 assertEquals(1, mContentResolver.delete(mScannerUri, null, null));
85 assertNull(mContentResolver.query(mScannerUri, PROJECTION, null, null, null));
MediaStore_Audio_ArtistsTest.java 30 private ContentResolver mContentResolver;
36 mContentResolver = getInstrumentation().getContext().getContentResolver();
41 assertNotNull(c = mContentResolver.query(
45 assertNotNull(c = mContentResolver.query(
52 assertNull(mContentResolver.query(Artists.getContentUri(volume), null, null, null, null));
67 mContentResolver.insert(artistsUri, new ContentValues());
73 Uri uri = isInternal ? Audio1.getInstance().insertToInternal(mContentResolver)
74 : Audio1.getInstance().insertToExternal(mContentResolver);
80 Cursor c = mContentResolver.query(artistsUri, null, selection, selectionArgs, null);
96 mContentResolver.update(artistsUri, artistValues, selection, selectionArgs)
    [all...]
MediaStore_Audio_AlbumsTest.java 39 private ContentResolver mContentResolver;
45 mContentResolver = mContext.getContentResolver();
50 assertNotNull(c = mContentResolver.query(
54 assertNotNull(c = mContentResolver.query(
61 assertNull(mContentResolver.query(Albums.getContentUri(volume), null, null, null, null));
76 mContentResolver.insert(audioAlbumsUri, new ContentValues());
84 Uri audioMediaUri = isInternal ? audio1.insertToInternal(mContentResolver)
85 : audio1.insertToExternal(mContentResolver);
91 Cursor c = mContentResolver.query(audioAlbumsUri, null, selection, selectionArgs,
126 mContentResolver.update(audioAlbumsUri, albumValues, selection, selectionArgs)
    [all...]
MediaStore_Audio_Artists_AlbumsTest.java 32 private ContentResolver mContentResolver;
38 mContentResolver = getInstrumentation().getContext().getContentResolver();
45 assertNotNull(c = mContentResolver.query(contentUri, null, null, null, null));
50 assertNotNull(c = mContentResolver.query(contentUri, null, null, null, null));
55 assertNull(mContentResolver.query(MediaStore.Audio.Artists.Albums.getContentUri(volume, 1),
69 Uri audioMediaUri = isInternal ? Audio1.getInstance().insertToInternal(mContentResolver)
70 : Audio1.getInstance().insertToExternal(mContentResolver);
72 Cursor c = mContentResolver.query(audioMediaUri, new String[] { Media.ARTIST_ID }, null,
82 mContentResolver.insert(artistsAlbumsUri, new ContentValues());
90 c = mContentResolver.query(artistsAlbumsUri, null, null, null, null)
    [all...]
MediaStore_Audio_Genres_MembersTest.java 33 private ContentResolver mContentResolver;
43 mContentResolver = getInstrumentation().getContext().getContentResolver();
44 Uri uri = Audio1.getInstance().insertToExternal(mContentResolver);
45 Cursor c = mContentResolver.query(uri, null, null, null, null);
50 uri = Audio2.getInstance().insertToExternal(mContentResolver);
51 c = mContentResolver.query(uri, null, null, null, null);
61 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mAudioIdOfJam, null);
62 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mAudioIdOfJamLive,
69 assertNotNull(c = mContentResolver.query(
75 assertNotNull(c = mContentResolver.query
    [all...]
MediaStore_Audio_PlaylistsTest.java 32 private ContentResolver mContentResolver;
38 mContentResolver = getInstrumentation().getContext().getContentResolver();
43 assertNotNull(c = mContentResolver.query(
50 assertNotNull(c = mContentResolver.query(
60 assertNull(mContentResolver.query(Playlists.getContentUri(volume), null, null, null,
74 Uri uri = mContentResolver.insert(Playlists.EXTERNAL_CONTENT_URI, values);
79 Cursor c = mContentResolver.query(uri, null, null, null, null);
97 assertEquals(1, mContentResolver.update(uri, values, null, null));
98 c = mContentResolver.query(uri, null, null, null, null);
108 assertEquals(1, mContentResolver.delete(uri, null, null))
    [all...]
TelephonyProviderTest.java 39 private ContentResolver mContentResolver;
50 mContentResolver = getInstrumentation().getContext().getContentResolver();
60 Uri uri2 = mContentResolver.insert(uri, values2);
67 int rowCnt = mContentResolver.update(uri2, values, null, null);
70 ParcelFileDescriptor pfd = mContentResolver.openFileDescriptor(uri2, "rw");
89 Cursor cursor = mContentResolver.query(Carriers.CONTENT_URI,
MediaStore_VideoTest.java 40 private ContentResolver mContentResolver;
47 mContentResolver.delete(row, null, null);
57 mContentResolver = mContext.getContentResolver();
67 Uri newUri = mContentResolver.insert(Video.Media.INTERNAL_CONTENT_URI, values);
72 Cursor c = Video.query(mContentResolver, newUri, new String[] { VideoColumns.DATA });
MediaStore_Images_ThumbnailsTest.java 46 private ContentResolver mContentResolver;
54 mContentResolver.delete(row, null, null);
70 mContentResolver = mContext.getContentResolver();
77 Cursor c = Thumbnails.queryMiniThumbnails(mContentResolver,
87 Uri uri = mContentResolver.insert(Thumbnails.INTERNAL_CONTENT_URI, values);
93 c = Thumbnails.queryMiniThumbnails(mContentResolver, uri, Thumbnails.MINI_KIND, null);
100 c = Thumbnails.queryMiniThumbnails(mContentResolver, Thumbnails.INTERNAL_CONTENT_URI,
106 c = Thumbnails.query(mContentResolver, uri, null);
121 stringUrl = Media.insertImage(mContentResolver, src, null, null);
130 Cursor c = mContentResolver.query(Uri.parse(stringUrl)
    [all...]
CalendarTest.java 78 private ContentResolver mContentResolver;
    [all...]
UserDictionary_WordsTest.java 31 private ContentResolver mContentResolver;
48 mContentResolver = mContext.getContentResolver();
55 mContentResolver.delete(row, null, null);
69 Cursor cursor = mContentResolver.query(UserDictionary.Words.CONTENT_URI, WORDS_PROJECTION,
93 Cursor cursor = mContentResolver.query(UserDictionary.Words.CONTENT_URI, WORDS_PROJECTION,
MediaStore_Images_MediaTest.java 59 private ContentResolver mContentResolver;
66 mContentResolver.delete(row, null, null);
78 mContentResolver = mContext.getContentResolver();
85 Cursor c = Media.query(mContentResolver, Media.EXTERNAL_CONTENT_URI, null, null,
94 stringUrl = Media.insertImage(mContentResolver, path, TEST_TITLE1, TEST_DESCRIPTION1);
108 stringUrl = Media.insertImage(mContentResolver, path, TEST_TITLE2, TEST_DESCRIPTION2);
119 c = Media.query(mContentResolver, Uri.parse(stringUrl),
130 c = Media.query(mContentResolver, Media.EXTERNAL_CONTENT_URI,
145 c = Media.query(mContentResolver, Uri.parse(stringUrl),
160 stringUrl = Media.insertImage(mContentResolver, src, TEST_TITLE3, TEST_DESCRIPTION3)
    [all...]
MediaStore_Audio_Playlists_MembersTest.java 96 private ContentResolver mContentResolver;
105 Uri uri = which.insertToExternal(mContentResolver);
106 Cursor c = mContentResolver.query(uri, null, null, null, null);
117 mContentResolver = getInstrumentation().getContext().getContentResolver();
127 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mIdOfAudio1, null);
128 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mIdOfAudio2, null);
129 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mIdOfAudio3, null);
130 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mIdOfAudio4, null);
131 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, Media._ID + "=" + mIdOfAudio5, null);
146 return mContentResolver.insert(playlistMembersUri, values)
    [all...]
Contacts_PeopleTest.java 44 private ContentResolver mContentResolver;
68 mContentResolver = getInstrumentation().getTargetContext().getContentResolver();
69 mProvider = mContentResolver.acquireContentProviderClient(Contacts.AUTHORITY);
126 mRowsAdded.add(People.addToMyContactsGroup(mContentResolver, personId));
132 cursor = People.queryGroups(mContentResolver, personId);
149 mRowsAdded.add(People.createPersonInMyContactsGroup(mContentResolver, values));
162 cursor = People.queryGroups(mContentResolver, personId);
179 mRowsAdded.add(People.addToGroup(mContentResolver, personId, groupId));
180 cursor = People.queryGroups(mContentResolver, personId);
200 mRowsAdded.add(People.addToGroup(mContentResolver, personId, groupName))
    [all...]
MediaStore_Audio_MediaTest.java 31 private ContentResolver mContentResolver;
37 mContentResolver = getInstrumentation().getContext().getContentResolver();
42 assertNotNull(c = mContentResolver.query(
46 assertNotNull(c = mContentResolver.query(
53 assertNull(mContentResolver.query(Media.getContentUri(volume), null, null, null, null));
59 assertNotNull(c = mContentResolver.query(Media.getContentUriForPath(externalPath), null, null,
65 assertNotNull(c = mContentResolver.query(Media.getContentUriForPath(internalPath), null, null,
83 Uri uri = mContentResolver.insert(mediaUri, values);
91 Cursor c = mContentResolver.query(uri, null, null, null, null);
132 int result = mContentResolver.update(uri, values, null, null)
    [all...]
MediaStore_Video_MediaTest.java 39 private ContentResolver mContentResolver;
45 mContentResolver = getContext().getContentResolver();
50 assertNotNull(c = mContentResolver.query(Media.getContentUri("internal"), null, null, null,
53 assertNotNull(c = mContentResolver.query(Media.getContentUri("external"), null, null, null,
59 assertNull(mContentResolver.query(Media.getContentUri(volume), null, null, null, null));
63 mContentResolver.delete(Media.EXTERNAL_CONTENT_URI, "_data=?", new String[] { path });
107 Uri uri = mContentResolver.insert(Media.EXTERNAL_CONTENT_URI, values);
112 Cursor c = mContentResolver.query(uri, null, null, null, null);
164 assertEquals(1, mContentResolver.update(uri, values, null, null));
166 c = mContentResolver.query(uri, null, null, null, null)
    [all...]
BrowserTest.java 43 private ContentResolver mContentResolver;
62 mContentResolver = mContext.getContentResolver();
63 mProvider = mContentResolver.acquireContentProviderClient(
149 Browser.addSearchUrl(mContentResolver, searchString);
161 Browser.addSearchUrl(mContentResolver, searchString);
173 Browser.addSearchUrl(mContentResolver, searchStringAnother);
186 Browser.clearSearches(mContentResolver);
204 cursor = Browser.getAllBookmarks(mContentResolver);
218 cursor = Browser.getAllBookmarks(mContentResolver);
236 cursor = Browser.getAllVisitedUrls(mContentResolver);
    [all...]
  /cts/tests/tests/content/src/android/content/cts/
ContentResolverTest.java 81 private ContentResolver mContentResolver;
89 mContentResolver = mContext.getContentResolver();
91 android.provider.Settings.System.putInt(mContentResolver, "__cts_crash_on_launch", 0);
98 mContentResolver.insert(TABLE1_URI, values);
99 mContentResolver.insert(REMOTE_TABLE1_URI, values);
103 mContentResolver.insert(TABLE1_URI, values);
104 mContentResolver.insert(REMOTE_TABLE1_URI, values);
108 mContentResolver.insert(TABLE1_URI, values);
109 mContentResolver.insert(REMOTE_TABLE1_URI, values);
114 mContentResolver.delete(TABLE1_URI, null, null)
    [all...]
  /cts/suite/cts/deviceTests/tvproviderperf/src/com/android/cts/tvproviderperf/
TvProviderPerfTest.java 52 private ContentResolver mContentResolver;
62 mContentResolver = getContext().getContentResolver();
70 mContentResolver.delete(Programs.CONTENT_URI, null, null);
71 mContentResolver.delete(Channels.CONTENT_URI, null, null);
101 mContentResolver.applyBatch(TvContract.AUTHORITY, operations);
113 try (final Cursor cursor = mContentResolver.query(Channels.CONTENT_URI,
128 mContentResolver.applyBatch(TvContract.AUTHORITY, operations);
143 mContentResolver.delete(TvContract.buildChannelsUriForInput(mInputId), null, null);
179 mContentResolver.applyBatch(TvContract.AUTHORITY, operations);
202 mContentResolver.applyBatch(TvContract.AUTHORITY, operations)
    [all...]
  /cts/tests/tests/tv/src/android/media/tv/cts/
TvContractTest.java 84 private ContentResolver mContentResolver;
95 mContentResolver = getContext().getContentResolver();
109 try (Cursor cursor = mContentResolver.query(mChannelsUri, projection, null, null, null)) {
112 mContentResolver.delete(
116 mContentResolver.delete(mChannelsUri, null, null);
182 try (Cursor cursor = mContentResolver.query(
216 Uri rowUri = mContentResolver.insert(mChannelsUri, values);
226 mContentResolver.update(channelUri, values, null, null);
230 mContentResolver.delete(mChannelsUri, null, null);
231 try (Cursor cursor = mContentResolver.query
    [all...]
  /development/samples/VoicemailProviderDemo/src/com/example/android/voicemail/common/core/
VoicemailProviderHelpers.java 56 private final ContentResolver mContentResolver;
67 mContentResolver = contentResolver;
106 return mContentResolver.insert(mBaseUri, contentValues);
114 return mContentResolver.update(uri, values, null, null);
139 outputStream = mContentResolver.openOutputStream(voicemailUri);
152 int updatedCount = mContentResolver.update(voicemailUri, values, null, null);
163 cursor = mContentResolver.query(mBaseUri, FULL_PROJECTION,
182 cursor = mContentResolver.query(uri, FULL_PROJECTION, null, null, null);
221 return mContentResolver.delete(mBaseUri, "", new String[0]);
235 cursor = mContentResolver.query(mBaseUri, FULL_PROJECTION
    [all...]
  /development/samples/RandomMusicPlayer/src/com/example/android/musicplayer/
MusicRetriever.java 39 ContentResolver mContentResolver;
47 mContentResolver = cr;
61 Cursor cur = mContentResolver.query(uri, null,
103 return mContentResolver;
  /cts/tests/tests/text/src/android/text/format/cts/
DateFormatTest.java 37 private ContentResolver mContentResolver;
55 mContentResolver = mContext.getContentResolver();
65 Settings.System.putString(mContentResolver, Settings.System.TIME_12_24, "12");
70 Settings.System.putString(mContentResolver, Settings.System.DATE_FORMAT, mDefaultFormat);
76 Settings.System.putString(mContentResolver, Settings.System.TIME_12_24, "24");
78 Settings.System.putString(mContentResolver, Settings.System.TIME_12_24, "12");
151 Settings.System.putString(mContentResolver, Settings.System.DATE_FORMAT, testFormat);

Completed in 635 milliseconds

1 2