/frameworks/support/documents-archive/tests/src/android/support/provider/ |
D | DocumentArchiveTest.java | 22 import android.provider.DocumentsContract.Document; 94 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_DOCUMENT_ID))); in testQueryChildDocument() 96 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_DISPLAY_NAME))); in testQueryChildDocument() 97 assertEquals(Document.MIME_TYPE_DIR, in testQueryChildDocument() 98 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_MIME_TYPE))); in testQueryChildDocument() 100 cursor.getInt(cursor.getColumnIndexOrThrow(Document.COLUMN_SIZE))); in testQueryChildDocument() 104 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_DOCUMENT_ID))); in testQueryChildDocument() 106 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_DISPLAY_NAME))); in testQueryChildDocument() 107 assertEquals(Document.MIME_TYPE_DIR, in testQueryChildDocument() 108 cursor.getString(cursor.getColumnIndexOrThrow(Document.COLUMN_MIME_TYPE))); in testQueryChildDocument() [all …]
|
D | StubProvider.java | 26 import android.provider.DocumentsContract.Document; 47 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_DISPLAY_NAME, Document.COLUMN_SIZE, 48 Document.COLUMN_MIME_TYPE, Document.COLUMN_FLAGS, 123 row.add(Document.COLUMN_DOCUMENT_ID, DOCUMENT_ID); in queryDocument() 124 row.add(Document.COLUMN_DISPLAY_NAME, file.getName()); in queryDocument() 125 row.add(Document.COLUMN_SIZE, file.length()); in queryDocument() 126 row.add(Document.COLUMN_MIME_TYPE, "application/zip"); in queryDocument() 128 ? Document.FLAG_ARCHIVE : 0; in queryDocument() 129 row.add(Document.COLUMN_FLAGS, flags); in queryDocument()
|
/frameworks/base/packages/MtpDocumentsProvider/src/com/android/mtp/ |
D | MtpDatabaseConstants.java | 21 import android.provider.DocumentsContract.Document; 61 Document.COLUMN_DOCUMENT_ID, 117 static final String SELECTION_DOCUMENT_ID = Document.COLUMN_DOCUMENT_ID + " = ?"; 122 Document.COLUMN_DOCUMENT_ID + 131 Document.COLUMN_MIME_TYPE + " TEXT NOT NULL," + 132 Document.COLUMN_DISPLAY_NAME + " TEXT NOT NULL," + 133 Document.COLUMN_SUMMARY + " TEXT," + 134 Document.COLUMN_LAST_MODIFIED + " INTEGER," + 135 Document.COLUMN_ICON + " INTEGER," + 136 Document.COLUMN_FLAGS + " INTEGER NOT NULL," + [all …]
|
D | MtpDatabase.java | 37 import android.provider.DocumentsContract.Document; 264 strings(Document.COLUMN_DOCUMENT_ID), in getStorageDocumentIds() 304 strings(Document.COLUMN_DOCUMENT_ID), in getDocumentIdForDevice() 352 strings(Document.COLUMN_DOCUMENT_ID), in getDeviceDocumentId() 452 strings(Document.COLUMN_DOCUMENT_ID), in deleteDocumentsAndRootsRecursively() 491 strings(Document.COLUMN_DOCUMENT_ID), in disconnectDocumentsRecursively() 524 new String[] { Document.COLUMN_DOCUMENT_ID }, in deleteDocumentsAndRoots() 602 Document.COLUMN_DOCUMENT_ID + " = ?", in updateObject() 620 "parent." + Document.COLUMN_DOCUMENT_ID; in getUnmappedDocumentsParent() 631 "parent." + Document.COLUMN_DOCUMENT_ID, in getUnmappedDocumentsParent() [all …]
|
/frameworks/base/packages/DocumentsUI/tests/src/com/android/documentsui/dirlist/ |
D | TestModel.java | 20 import android.provider.DocumentsContract.Document; 31 Document.COLUMN_DOCUMENT_ID, 32 Document.COLUMN_FLAGS, 33 Document.COLUMN_DISPLAY_NAME, 34 Document.COLUMN_SIZE, 35 Document.COLUMN_MIME_TYPE 52 row.add(Document.COLUMN_DOCUMENT_ID, Integer.toString(i)); in update() 53 row.add(Document.COLUMN_FLAGS, Document.FLAG_SUPPORTS_DELETE); in update() 56 row.add(Document.COLUMN_DISPLAY_NAME, names[i]); in update() 57 row.add(Document.COLUMN_SIZE, rand.nextInt()); in update()
|
D | ModelTest.java | 25 import android.provider.DocumentsContract.Document; 52 Document.COLUMN_DOCUMENT_ID, 53 Document.COLUMN_FLAGS, 54 Document.COLUMN_DISPLAY_NAME, 55 Document.COLUMN_SIZE, 56 Document.COLUMN_LAST_MODIFIED, 57 Document.COLUMN_MIME_TYPE 87 row.add(Document.COLUMN_DOCUMENT_ID, Integer.toString(i)); in setUp() 88 row.add(Document.COLUMN_FLAGS, Document.FLAG_SUPPORTS_DELETE); in setUp() 91 row.add(Document.COLUMN_DISPLAY_NAME, NAMES[i]); in setUp() [all …]
|
D | SectionBreakDocumentsAdapterWrapperTest.java | 22 import android.provider.DocumentsContract.Document; 73 row.add(Document.COLUMN_DOCUMENT_ID, Integer.toString(i)); in testItemCount_allDirs() 74 row.add(Document.COLUMN_SIZE, i); in testItemCount_allDirs() 75 row.add(Document.COLUMN_MIME_TYPE, Document.MIME_TYPE_DIR); in testItemCount_allDirs() 98 row.add(Document.COLUMN_DOCUMENT_ID, Integer.toString(i)); in testItemCount_mixed() 99 row.add(Document.COLUMN_SIZE, i); in testItemCount_mixed() 100 String mimeType =(i < 2) ? Document.MIME_TYPE_DIR : "text/*"; in testItemCount_mixed() 101 row.add(Document.COLUMN_MIME_TYPE, mimeType); in testItemCount_mixed()
|
/frameworks/base/packages/Shell/src/com/android/shell/ |
D | BugreportStorageProvider.java | 27 import android.provider.DocumentsContract.Document; 46 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_MIME_TYPE, Document.COLUMN_DISPLAY_NAME, 47 Document.COLUMN_LAST_MODIFIED, Document.COLUMN_FLAGS, Document.COLUMN_SIZE, 82 row.add(Document.COLUMN_DOCUMENT_ID, documentId); in queryDocument() 83 row.add(Document.COLUMN_MIME_TYPE, Document.MIME_TYPE_DIR); in queryDocument() 84 row.add(Document.COLUMN_DISPLAY_NAME, mRoot.getName()); in queryDocument() 85 row.add(Document.COLUMN_LAST_MODIFIED, mRoot.lastModified()); in queryDocument() 86 row.add(Document.COLUMN_FLAGS, Document.FLAG_DIR_PREFERS_LAST_MODIFIED); in queryDocument() 183 int flags = Document.FLAG_SUPPORTS_DELETE; in addFileRow() 185 flags |= Document.FLAG_ARCHIVE; in addFileRow() [all …]
|
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/model/ |
D | DocumentInfo.java | 26 import android.provider.DocumentsContract.Document; 156 this.documentId = getCursorString(cursor, Document.COLUMN_DOCUMENT_ID); in updateFromCursor() 157 this.mimeType = getCursorString(cursor, Document.COLUMN_MIME_TYPE); in updateFromCursor() 158 this.displayName = getCursorString(cursor, Document.COLUMN_DISPLAY_NAME); in updateFromCursor() 159 this.lastModified = getCursorLong(cursor, Document.COLUMN_LAST_MODIFIED); in updateFromCursor() 160 this.flags = getCursorInt(cursor, Document.COLUMN_FLAGS); in updateFromCursor() 161 this.summary = getCursorString(cursor, Document.COLUMN_SUMMARY); in updateFromCursor() 162 this.size = getCursorLong(cursor, Document.COLUMN_SIZE); in updateFromCursor() 163 this.icon = getCursorInt(cursor, Document.COLUMN_ICON); in updateFromCursor() 223 return (flags & Document.FLAG_DIR_SUPPORTS_CREATE) != 0; in isCreateSupported() [all …]
|
/frameworks/support/v4/kitkat/android/support/v4/provider/ |
D | DocumentsContractApi19.java | 37 return queryForString(context, self, DocumentsContract.Document.COLUMN_DISPLAY_NAME, null); in getName() 41 return queryForString(context, self, DocumentsContract.Document.COLUMN_MIME_TYPE, null); in getRawType() 46 if (DocumentsContract.Document.MIME_TYPE_DIR.equals(rawType)) { in getType() 54 return DocumentsContract.Document.MIME_TYPE_DIR.equals(getRawType(context, self)); in isDirectory() 59 if (DocumentsContract.Document.MIME_TYPE_DIR.equals(type) || TextUtils.isEmpty(type)) { in isFile() 67 return queryForLong(context, self, DocumentsContract.Document.COLUMN_LAST_MODIFIED, 0); in lastModified() 71 return queryForLong(context, self, DocumentsContract.Document.COLUMN_SIZE, 0); in length() 97 final int flags = queryForInt(context, self, DocumentsContract.Document.COLUMN_FLAGS, 0); in canWrite() 105 if ((flags & DocumentsContract.Document.FLAG_SUPPORTS_DELETE) != 0) { in canWrite() 109 if (DocumentsContract.Document.MIME_TYPE_DIR.equals(type) in canWrite() [all …]
|
/frameworks/base/packages/DocumentsUI/perf-tests/src/com/android/documentsui/ |
D | StressProvider.java | 29 import android.provider.DocumentsContract.Document; 75 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_MIME_TYPE, Document.COLUMN_DISPLAY_NAME, 76 Document.COLUMN_LAST_MODIFIED, Document.COLUMN_FLAGS, Document.COLUMN_SIZE, 188 row.add(Document.COLUMN_DOCUMENT_ID, document.id); in includeDocument() 189 row.add(Document.COLUMN_DISPLAY_NAME, document.id); in includeDocument() 190 row.add(Document.COLUMN_SIZE, document.size); in includeDocument() 191 row.add(Document.COLUMN_MIME_TYPE, document.mimeType); in includeDocument() 192 row.add(Document.COLUMN_FLAGS, in includeDocument() 193 document.thumbnail != -1 ? Document.FLAG_SUPPORTS_THUMBNAIL : 0); in includeDocument() 194 row.add(Document.COLUMN_LAST_MODIFIED, document.lastModified); in includeDocument() [all …]
|
/frameworks/base/packages/ExternalStorageProvider/src/com/android/externalstorage/ |
D | TestDocumentsProvider.java | 40 import android.provider.DocumentsContract.Document; 89 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_MIME_TYPE, Document.COLUMN_DISPLAY_NAME, 90 Document.COLUMN_LAST_MODIFIED, Document.COLUMN_FLAGS, Document.COLUMN_SIZE, 242 includeFile(result, "localfile2", Document.FLAG_SUPPORTS_THUMBNAIL); in queryChildDocuments() 248 includeFile(result, "i maded u an picshure" + i, Document.FLAG_SUPPORTS_THUMBNAIL); in queryChildDocuments() 395 row.add(Document.COLUMN_DOCUMENT_ID, docId); in includeFile() 396 row.add(Document.COLUMN_DISPLAY_NAME, docId); in includeFile() 397 row.add(Document.COLUMN_LAST_MODIFIED, System.currentTimeMillis()); in includeFile() 398 row.add(Document.COLUMN_FLAGS, flags); in includeFile() 401 row.add(Document.COLUMN_MIME_TYPE, Document.MIME_TYPE_DIR); in includeFile() [all …]
|
D | ExternalStorageProvider.java | 41 import android.provider.DocumentsContract.Document; 83 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_MIME_TYPE, Document.COLUMN_DISPLAY_NAME, 84 Document.COLUMN_LAST_MODIFIED, Document.COLUMN_FLAGS, Document.COLUMN_SIZE, 360 flags |= Document.FLAG_DIR_SUPPORTS_CREATE; in includeFile() 361 flags |= Document.FLAG_SUPPORTS_DELETE; in includeFile() 362 flags |= Document.FLAG_SUPPORTS_RENAME; in includeFile() 363 flags |= Document.FLAG_SUPPORTS_MOVE; in includeFile() 365 flags |= Document.FLAG_SUPPORTS_WRITE; in includeFile() 366 flags |= Document.FLAG_SUPPORTS_DELETE; in includeFile() 367 flags |= Document.FLAG_SUPPORTS_RENAME; in includeFile() [all …]
|
/frameworks/base/packages/MtpDocumentsProvider/tests/src/com/android/mtp/ |
D | MtpDatabaseTest.java | 26 import android.provider.DocumentsContract.Document; 34 import static android.provider.DocumentsContract.Document.*; 42 DocumentsContract.Document.COLUMN_DOCUMENT_ID, 46 DocumentsContract.Document.COLUMN_MIME_TYPE, 47 DocumentsContract.Document.COLUMN_DISPLAY_NAME, 48 DocumentsContract.Document.COLUMN_SUMMARY, 49 DocumentsContract.Document.COLUMN_LAST_MODIFIED, 50 DocumentsContract.Document.COLUMN_ICON, 51 DocumentsContract.Document.COLUMN_FLAGS, 52 DocumentsContract.Document.COLUMN_SIZE, [all …]
|
D | MtpDocumentsProviderTest.java | 26 import android.provider.DocumentsContract.Document; 319 DocumentsContract.Document.FLAG_SUPPORTS_DELETE | in testQueryDocument() 320 DocumentsContract.Document.FLAG_SUPPORTS_WRITE | in testQueryDocument() 321 DocumentsContract.Document.FLAG_SUPPORTS_THUMBNAIL, in testQueryDocument() 350 assertEquals(DocumentsContract.Document.MIME_TYPE_DIR, cursor.getString(1)); in testQueryDocument_directory() 354 DocumentsContract.Document.FLAG_SUPPORTS_DELETE | in testQueryDocument_directory() 355 DocumentsContract.Document.FLAG_DIR_SUPPORTS_CREATE, in testQueryDocument_directory() 377 assertEquals(DocumentsContract.Document.MIME_TYPE_DIR, cursor.getString(1)); in testQueryDocument_forRoot() 411 assertEquals(Document.FLAG_SUPPORTS_THUMBNAIL, cursor.getInt(4)); in testQueryChildDocuments() 652 strings(Document.COLUMN_DOCUMENT_ID, Document.COLUMN_DISPLAY_NAME), in testMappingDisconnectedDocuments() [all …]
|
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/dirlist/ |
D | ListDocumentHolder.java | 27 import android.provider.DocumentsContract.Document; 118 final String docId = getCursorString(cursor, Document.COLUMN_DOCUMENT_ID); in bind() 119 final String docMimeType = getCursorString(cursor, Document.COLUMN_MIME_TYPE); in bind() 120 final String docDisplayName = getCursorString(cursor, Document.COLUMN_DISPLAY_NAME); in bind() 121 final long docLastModified = getCursorLong(cursor, Document.COLUMN_LAST_MODIFIED); in bind() 122 final int docIcon = getCursorInt(cursor, Document.COLUMN_ICON); in bind() 123 final int docFlags = getCursorInt(cursor, Document.COLUMN_FLAGS); in bind() 124 final String docSummary = getCursorString(cursor, Document.COLUMN_SUMMARY); in bind() 125 final long docSize = getCursorLong(cursor, Document.COLUMN_SIZE); in bind() 126 final boolean isDirectory = Document.MIME_TYPE_DIR.equals(docMimeType); in bind()
|
D | GridDocumentHolder.java | 28 import android.provider.DocumentsContract.Document; 122 final String docId = getCursorString(cursor, Document.COLUMN_DOCUMENT_ID); in bind() 123 final String docMimeType = getCursorString(cursor, Document.COLUMN_MIME_TYPE); in bind() 124 final String docDisplayName = getCursorString(cursor, Document.COLUMN_DISPLAY_NAME); in bind() 125 final long docLastModified = getCursorLong(cursor, Document.COLUMN_LAST_MODIFIED); in bind() 126 final int docIcon = getCursorInt(cursor, Document.COLUMN_ICON); in bind() 127 final int docFlags = getCursorInt(cursor, Document.COLUMN_FLAGS); in bind() 128 final long docSize = getCursorLong(cursor, Document.COLUMN_SIZE); in bind() 154 if (!state.showSize || Document.MIME_TYPE_DIR.equals(docMimeType) || docSize == -1) { in bind()
|
D | Model.java | 30 import android.provider.DocumentsContract.Document; 164 getCursorString(mCursor, Document.COLUMN_DOCUMENT_ID); in updateModelData() 166 mIds[pos] = getCursorString(mCursor, Document.COLUMN_DOCUMENT_ID); in updateModelData() 169 mimeType = getCursorString(mCursor, Document.COLUMN_MIME_TYPE); in updateModelData() 170 isDirs[pos] = Document.MIME_TYPE_DIR.equals(mimeType); in updateModelData() 175 mCursor, Document.COLUMN_DISPLAY_NAME); in updateModelData() 182 longValues[pos] = getCursorLong(mCursor, Document.COLUMN_SIZE); in updateModelData() 364 long l = getCursorLong(mCursor, Document.COLUMN_LAST_MODIFIED); in getLastModified()
|
D | DocumentsAdapter.java | 23 import android.provider.DocumentsContract.Document; 86 final String mimeType = getCursorString(cursor, Document.COLUMN_MIME_TYPE); in isDirectory() 87 return Document.MIME_TYPE_DIR.equals(mimeType); in isDirectory()
|
/frameworks/base/packages/DocumentsUI/tests/src/com/android/documentsui/ |
D | StubProvider.java | 33 import android.provider.DocumentsContract.Document; 83 Document.COLUMN_DOCUMENT_ID, Document.COLUMN_MIME_TYPE, Document.COLUMN_DISPLAY_NAME, 84 Document.COLUMN_LAST_MODIFIED, Document.COLUMN_FLAGS, Document.COLUMN_SIZE, 324 if ((document.flags & Document.FLAG_VIRTUAL_DOCUMENT) != 0) { in openDocument() 502 extras.getString(Document.COLUMN_MIME_TYPE), in createVirtualFileFromBundle() 508 result.putString(Document.COLUMN_DOCUMENT_ID, documentId); in createVirtualFileFromBundle() 519 String mimeType = extras.getString(Document.COLUMN_MIME_TYPE); in dispatchCreateDocumentWithFlags() 520 String name = extras.getString(Document.COLUMN_DISPLAY_NAME); in dispatchCreateDocumentWithFlags() 572 if (mimeType.equals(Document.MIME_TYPE_DIR)) { in createFile() 610 row.add(Document.COLUMN_DOCUMENT_ID, document.documentId); in includeDocument() [all …]
|
/frameworks/base/packages/DocumentsUI/tests/src/com/android/documentsui/services/ |
D | CopyJobTest.java | 22 import android.provider.DocumentsContract.Document; 50 Document.FLAG_VIRTUAL_DOCUMENT | Document.FLAG_SUPPORTS_COPY in testCopy_BackendSideVirtualTypedFile_Fallback() 51 | Document.FLAG_SUPPORTS_MOVE, "application/pdf"); in testCopy_BackendSideVirtualTypedFile_Fallback()
|
D | MoveJobTest.java | 22 import android.provider.DocumentsContract.Document; 65 Document.FLAG_VIRTUAL_DOCUMENT | Document.FLAG_SUPPORTS_COPY in testMove_BackendSideVirtualTypedFile_Fallback() 66 | Document.FLAG_SUPPORTS_MOVE, "application/pdf"); in testMove_BackendSideVirtualTypedFile_Fallback()
|
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/services/ |
D | CopyJob.java | 47 import android.provider.DocumentsContract.Document; 295 if ((src.flags & Document.FLAG_SUPPORTS_COPY) != 0) { in processDocument() 371 if (Document.MIME_TYPE_DIR.equals(src.mimeType)) { in byteCopyDocument() 391 Document.COLUMN_DISPLAY_NAME, in copyDirectoryHelper() 392 Document.COLUMN_DOCUMENT_ID, in copyDirectoryHelper() 393 Document.COLUMN_MIME_TYPE, in copyDirectoryHelper() 394 Document.COLUMN_SIZE, in copyDirectoryHelper() 395 Document.COLUMN_FLAGS in copyDirectoryHelper() 577 Document.COLUMN_DOCUMENT_ID, in calculateFileSizesRecursively() 578 Document.COLUMN_MIME_TYPE, in calculateFileSizesRecursively() [all …]
|
/frameworks/support/documents-archive/src/android/support/provider/ |
D | DocumentArchive.java | 31 import android.provider.DocumentsContract.Document; 74 Document.COLUMN_DOCUMENT_ID, 75 Document.COLUMN_DISPLAY_NAME, 76 Document.COLUMN_MIME_TYPE, 77 Document.COLUMN_SIZE, 78 Document.COLUMN_FLAGS 505 row.add(Document.COLUMN_DOCUMENT_ID, parsedId.toDocumentId(mIdDelimiter)); in addCursorRow() 508 row.add(Document.COLUMN_DISPLAY_NAME, file.getName()); in addCursorRow() 509 row.add(Document.COLUMN_SIZE, entry.getSize()); in addCursorRow() 512 row.add(Document.COLUMN_MIME_TYPE, mimeType); in addCursorRow() [all …]
|
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/ |
D | DirectoryLoader.java | 35 import android.provider.DocumentsContract.Document; 48 private static final String[] SEARCH_REJECT_MIMES = new String[] { Document.MIME_TYPE_DIR }; 104 if ((mDoc.flags & Document.FLAG_DIR_PREFERS_LAST_MODIFIED) != 0) { in loadInBackground() 218 return Document.COLUMN_DISPLAY_NAME + " ASC"; in getQuerySortOrder() 220 return Document.COLUMN_LAST_MODIFIED + " DESC"; in getQuerySortOrder() 222 return Document.COLUMN_SIZE + " DESC"; in getQuerySortOrder()
|