Android.OS.ParcelFileDescriptor.Open Method
Create a new ParcelFileDescriptor accessing a given file.

Syntax

[Android.Runtime.Register("open", "(Ljava/io/File;I)Landroid/os/ParcelFileDescriptor;", "")]
public static ParcelFileDescriptor Open (Java.IO.File file, [Android.Runtime.GeneratedEnum] ParcelFileMode mode)

See Also

ParcelFileDescriptor.ParseMode(string)

Parameters

file
The file to be opened.
mode
The desired access mode, must be one of ParcelFileDescriptor.MODE_READ_ONLY, ParcelFileDescriptor.MODE_WRITE_ONLY, or ParcelFileDescriptor.MODE_READ_WRITE; may also be any combination of ParcelFileDescriptor.MODE_CREATE, ParcelFileDescriptor.MODE_TRUNCATE, ParcelFileDescriptor.MODE_WORLD_READABLE, and ParcelFileDescriptor.MODE_WORLD_WRITEABLE.

Returns

Documentation for this section has not yet been entered.

Exceptions

TypeReason
Java.IO.FileNotFoundExceptionif the given file does not exist or can not be opened with the requested mode.

Remarks

Create a new ParcelFileDescriptor accessing a given file.

[Android Documentation]

Requirements

Namespace: Android.OS
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1