Share via


FileChannel.Open Method

Definition

Overloads

Open(IPath, IOpenOption[])

Opens or creates a file, returning a file channel to access the file.

Open(IPath, ICollection<IOpenOption>, IFileAttribute[])

Opens or creates a file, returning a file channel to access the file.

Open(IPath, IOpenOption[])

Opens or creates a file, returning a file channel to access the file.

[Android.Runtime.Register("open", "(Ljava/nio/file/Path;[Ljava/nio/file/OpenOption;)Ljava/nio/channels/FileChannel;", "", ApiSince=26)]
public static Java.Nio.Channels.FileChannel? Open (Java.Nio.FileNio.IPath? path, params Java.Nio.FileNio.IOpenOption[]? options);
[<Android.Runtime.Register("open", "(Ljava/nio/file/Path;[Ljava/nio/file/OpenOption;)Ljava/nio/channels/FileChannel;", "", ApiSince=26)>]
static member Open : Java.Nio.FileNio.IPath * Java.Nio.FileNio.IOpenOption[] -> Java.Nio.Channels.FileChannel

Parameters

path
IPath

The path of the file to open or create

options
IOpenOption[]

Options specifying how the file is opened

Returns

A new file channel

Attributes

Remarks

Java documentation for java.nio.channels.FileChannel.open(java.nio.file.Path, java.nio.file.OpenOption).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Open(IPath, ICollection<IOpenOption>, IFileAttribute[])

Opens or creates a file, returning a file channel to access the file.

[Android.Runtime.Register("open", "(Ljava/nio/file/Path;Ljava/util/Set;[Ljava/nio/file/attribute/FileAttribute;)Ljava/nio/channels/FileChannel;", "", ApiSince=26)]
public static Java.Nio.Channels.FileChannel? Open (Java.Nio.FileNio.IPath? path, System.Collections.Generic.ICollection<Java.Nio.FileNio.IOpenOption>? options, params Java.Nio.FileNio.Attributes.IFileAttribute[]? attrs);
[<Android.Runtime.Register("open", "(Ljava/nio/file/Path;Ljava/util/Set;[Ljava/nio/file/attribute/FileAttribute;)Ljava/nio/channels/FileChannel;", "", ApiSince=26)>]
static member Open : Java.Nio.FileNio.IPath * System.Collections.Generic.ICollection<Java.Nio.FileNio.IOpenOption> * Java.Nio.FileNio.Attributes.IFileAttribute[] -> Java.Nio.Channels.FileChannel

Parameters

path
IPath

The path of the file to open or create

options
ICollection<IOpenOption>

Options specifying how the file is opened

attrs
IFileAttribute[]

Returns

A new file channel

Attributes

Remarks

Java documentation for java.nio.channels.FileChannel.open(java.nio.file.Path, java.nio.file.OpenOption).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to