documentsprovider api official way manage files on removable storage since android 5.0. but, seems, not support basic functionality. or, maybe, missed something?
create new document (file) non-standard extension.
documentscontract.createdocument(contentresolver, uri, mimetype, name)
appends extension according mimetype. example, adds.txt'text/plain' mime-type. question is: can create file namefile.abc? if no, can register new mime-type, linkedabcextension?move document.
documentscontract.renamedocument(contentresolver, uri, newname)
can rename document. can move document directory (change parent of document)? must create new document, copy content old one, , delete old document?set modification date of document.
operation can useful in situation. example, in case must emulate filesystemmoveoperation question 2. there way set required modification time document?
yes can, depends on how documentprovider implemented device manufacturer.
you can rename, parent cannot moved. you're right creating new document.
no, setting last modified date not allowed till android 6.0. maybe in future.
Comments
Post a Comment