Android.Provider.DocumentsProvider.RenameDocument Method
Rename an existing document.

Syntax

[Android.Runtime.Register("renameDocument", "(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;", "GetRenameDocument_Ljava_lang_String_Ljava_lang_String_Handler")]
public virtual string RenameDocument (string documentId, string displayName)

Parameters

documentId
the document to rename.
displayName
the updated display name of the document. The provider may alter this name to meet any internal constraints, such as avoiding conflicting names.

Returns

Documentation for this section has not yet been entered.

Exceptions

TypeReason
Java.IO.FileNotFoundException

Remarks

Rename an existing document.

If a different NoType:android/provider/DocumentsContract$Document;Href=../../../reference/android/provider/DocumentsContract.Document.html#COLUMN_DOCUMENT_ID must be used to represent the renamed document, generate and return it. Any outstanding URI permission grants will be updated to point at the new document. If the original NoType:android/provider/DocumentsContract$Document;Href=../../../reference/android/provider/DocumentsContract.Document.html#COLUMN_DOCUMENT_ID is still valid after the rename, return null.

[Android Documentation]

Requirements

Namespace: Android.Provider
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0