'' Initializes a new instance of the System.IO.FileStream class for the specified
'' file handle, with the specified read/write permission, and buffer size.
''
'' Parameters:
'' handle:
'' A file handle for the file that the current FileStream object will encapsulate.
''
'' access:
'' A System.IO.FileAccess constant that sets the System.IO.FileStream.CanRead and
'' System.IO.FileStream.CanWrite properties of the FileStream object.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' Exceptions:
'' T:System.ArgumentException:
'' The handle parameter is an invalid handle.-or-The handle parameter is a synchronous
'' handle and it was used asynchronously.
''
'' T:System.ArgumentOutOfRangeException:
'' The bufferSize parameter is negative.
''
'' T:System.IO.IOException:
'' An I/O error, such as a disk error, occurred.-or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' file handle, such as when access is Write or ReadWrite and the file handle is
'' set for read-only access.
'<SecuritySafeCritical>
'Public Sub New(handle As SafeFileHandle, access As FileAccess, bufferSize As Integer)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, read/write permission, and sharing permission.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current FileStream object will
'' encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' access:
'' A constant that determines how the file can be accessed by the FileStream object.
'' This also determines the values returned by the System.IO.FileStream.CanRead
'' and System.IO.FileStream.CanWrite properties of the FileStream object. System.IO.FileStream.CanSeek
'' is true if path specifies a disk file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred. -or-The system is running Windows 98 or Windows
'' 98 Second Edition and share is set to FileShare.Delete.-or-The stream has been
'' closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
''
'' T:System.ArgumentOutOfRangeException:
'' mode contains an invalid value.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, access As FileAccess, share As FileShare)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class for the specified
'' file handle, with the specified read/write permission, buffer size, and synchronous
'' or asynchronous state.
''
'' Parameters:
'' handle:
'' A file handle for the file that this FileStream object will encapsulate.
''
'' access:
'' A constant that sets the System.IO.FileStream.CanRead and System.IO.FileStream.CanWrite
'' properties of the FileStream object.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' isAsync:
'' true if the handle was opened asynchronously (that is, in overlapped I/O mode);
'' otherwise, false.
''
'' Exceptions:
'' T:System.ArgumentException:
'' The handle parameter is an invalid handle.-or-The handle parameter is a synchronous
'' handle and it was used asynchronously.
''
'' T:System.ArgumentOutOfRangeException:
'' The bufferSize parameter is negative.
''
'' T:System.IO.IOException:
'' An I/O error, such as a disk error, occurred.-or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' file handle, such as when access is Write or ReadWrite and the file handle is
'' set for read-only access.
'<SecuritySafeCritical>
'Public Sub New(handle As SafeFileHandle, access As FileAccess, bufferSize As Integer, isAsync As Boolean)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class for the specified
'' file handle, with the specified read/write permission, FileStream instance ownership,
'' and buffer size.
''
'' Parameters:
'' handle:
'' A file handle for the file that this FileStream object will encapsulate.
''
'' access:
'' A constant that sets the System.IO.FileStream.CanRead and System.IO.FileStream.CanWrite
'' properties of the FileStream object.
''
'' ownsHandle:
'' true if the file handle will be owned by this FileStream instance; otherwise,
'' false.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' Exceptions:
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative.
''
'' T:System.IO.IOException:
'' An I/O error, such as a disk error, occurred.-or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' file handle, such as when access is Write or ReadWrite and the file handle is
'' set for read-only access.
'<Obsolete("This constructor has been deprecated. Please use new FileStream(SafeFileHandle handle, FileAccess access, int bufferSize) instead, and optionally make a new SafeFileHandle with ownsHandle=false if needed. http://go.microsoft.com/fwlink/?linkid=14202")>
'Public Sub New(handle As IntPtr, access As FileAccess, ownsHandle As Boolean, bufferSize As Integer)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class for the specified
'' file handle, with the specified read/write permission, FileStream instance ownership,
'' buffer size, and synchronous or asynchronous state.
''
'' Parameters:
'' handle:
'' A file handle for the file that this FileStream object will encapsulate.
''
'' access:
'' A constant that sets the System.IO.FileStream.CanRead and System.IO.FileStream.CanWrite
'' properties of the FileStream object.
''
'' ownsHandle:
'' true if the file handle will be owned by this FileStream instance; otherwise,
'' false.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' isAsync:
'' true if the handle was opened asynchronously (that is, in overlapped I/O mode);
'' otherwise, false.
''
'' Exceptions:
'' T:System.ArgumentOutOfRangeException:
'' access is less than FileAccess.Read or greater than FileAccess.ReadWrite or bufferSize
'' is less than or equal to 0.
''
'' T:System.ArgumentException:
'' The handle is invalid.
''
'' T:System.IO.IOException:
'' An I/O error, such as a disk error, occurred.-or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' file handle, such as when access is Write or ReadWrite and the file handle is
'' set for read-only access.
'<Obsolete("This constructor has been deprecated. Please use new FileStream(SafeFileHandle handle, FileAccess access, int bufferSize, bool isAsync) instead, and optionally make a new SafeFileHandle with ownsHandle=false if needed. http://go.microsoft.com/fwlink/?linkid=14202")> <SecuritySafeCritical>
'Public Sub New(handle As IntPtr, access As FileAccess, ownsHandle As Boolean, bufferSize As Integer, isAsync As Boolean)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, read/write and sharing permission, and buffer size.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current FileStream object will
'' encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' access:
'' A constant that determines how the file can be accessed by the FileStream object.
'' This also determines the values returned by the System.IO.FileStream.CanRead
'' and System.IO.FileStream.CanWrite properties of the FileStream object. System.IO.FileStream.CanSeek
'' is true if path specifies a disk file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative or zero.-or- mode, access, or share contain an invalid
'' value.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred. -or-The system is running Windows 98 or Windows
'' 98 Second Edition and share is set to FileShare.Delete.-or-The stream has been
'' closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, access As FileAccess, share As FileShare, bufferSize As Integer)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, read/write and sharing permission, buffer size, and synchronous
'' or asynchronous state.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current FileStream object will
'' encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' access:
'' A constant that determines how the file can be accessed by the FileStream object.
'' This also determines the values returned by the System.IO.FileStream.CanRead
'' and System.IO.FileStream.CanWrite properties of the FileStream object. System.IO.FileStream.CanSeek
'' is true if path specifies a disk file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096..
''
'' useAsync:
'' Specifies whether to use asynchronous I/O or synchronous I/O. However, note that
'' the underlying operating system might not support asynchronous I/O, so when specifying
'' true, the handle might be opened synchronously depending on the platform. When
'' opened asynchronously, the System.IO.FileStream.BeginRead(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)
'' and System.IO.FileStream.BeginWrite(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)
'' methods perform better on large reads or writes, but they might be much slower
'' for small reads or writes. If the application is designed to take advantage of
'' asynchronous I/O, set the useAsync parameter to true. Using asynchronous I/O
'' correctly can speed up applications by as much as a factor of 10, but using it
'' without redesigning the application for asynchronous I/O can decrease performance
'' by as much as a factor of 10.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative or zero.-or- mode, access, or share contain an invalid
'' value.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred.-or- The system is running Windows 98 or Windows
'' 98 Second Edition and share is set to FileShare.Delete.-or-The stream has been
'' closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, access As FileAccess, share As FileShare, bufferSize As Integer, useAsync As Boolean)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, read/write and sharing permission, the access other FileStreams
'' can have to the same file, the buffer size, and additional file options.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current FileStream object will
'' encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' access:
'' A constant that determines how the file can be accessed by the FileStream object.
'' This also determines the values returned by the System.IO.FileStream.CanRead
'' and System.IO.FileStream.CanWrite properties of the FileStream object. System.IO.FileStream.CanSeek
'' is true if path specifies a disk file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' options:
'' A value that specifies additional file options.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative or zero.-or- mode, access, or share contain an invalid
'' value.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred.-or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access. -or-System.IO.FileOptions.Encrypted is specified for
'' options, but file encryption is not supported on the current platform.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, access As FileAccess, share As FileShare, bufferSize As Integer, options As FileOptions)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, access rights and sharing permission, the buffer size, and
'' additional file options.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current System.IO.FileStream
'' object will encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' rights:
'' A constant that determines the access rights to use when creating access and
'' audit rules for the file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' options:
'' A constant that specifies additional file options.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative or zero.-or- mode, access, or share contain an invalid
'' value.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.PlatformNotSupportedException:
'' The current operating system is not Windows NT or later.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred. -or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access. -or-System.IO.FileOptions.Encrypted is specified for
'' options, but file encryption is not supported on the current platform.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, rights As FileSystemRights, share As FileShare, bufferSize As Integer, options As FileOptions)
'End Sub
''
'' Summary:
'' Initializes a new instance of the System.IO.FileStream class with the specified
'' path, creation mode, access rights and sharing permission, the buffer size, additional
'' file options, access control and audit security.
''
'' Parameters:
'' path:
'' A relative or absolute path for the file that the current System.IO.FileStream
'' object will encapsulate.
''
'' mode:
'' A constant that determines how to open or create the file.
''
'' rights:
'' A constant that determines the access rights to use when creating access and
'' audit rules for the file.
''
'' share:
'' A constant that determines how the file will be shared by processes.
''
'' bufferSize:
'' A positive System.Int32 value greater than 0 indicating the buffer size. The
'' default buffer size is 4096.
''
'' options:
'' A constant that specifies additional file options.
''
'' fileSecurity:
'' A constant that determines the access control and audit security for the file.
''
'' Exceptions:
'' T:System.ArgumentNullException:
'' path is null.
''
'' T:System.ArgumentException:
'' path is an empty string (""), contains only white space, or contains one or more
'' invalid characters. -or-path refers to a non-file device, such as "con:", "com1:",
'' "lpt1:", etc. in an NTFS environment.
''
'' T:System.NotSupportedException:
'' path refers to a non-file device, such as "con:", "com1:", "lpt1:", etc. in a
'' non-NTFS environment.
''
'' T:System.ArgumentOutOfRangeException:
'' bufferSize is negative or zero.-or- mode, access, or share contain an invalid
'' value.
''
'' T:System.IO.FileNotFoundException:
'' The file cannot be found, such as when mode is FileMode.Truncate or FileMode.Open,
'' and the file specified by path does not exist. The file must already exist in
'' these modes.
''
'' T:System.IO.IOException:
'' An I/O error, such as specifying FileMode.CreateNew when the file specified by
'' path already exists, occurred. -or-The stream has been closed.
''
'' T:System.Security.SecurityException:
'' The caller does not have the required permission.
''
'' T:System.IO.DirectoryNotFoundException:
'' The specified path is invalid, such as being on an unmapped drive.
''
'' T:System.UnauthorizedAccessException:
'' The access requested is not permitted by the operating system for the specified
'' path, such as when access is Write or ReadWrite and the file or directory is
'' set for read-only access. -or-System.IO.FileOptions.Encrypted is specified for
'' options, but file encryption is not supported on the current platform.
''
'' T:System.IO.PathTooLongException:
'' The specified path, file name, or both exceed the system-defined maximum length.
'' For example, on Windows-based platforms, paths must be less than 248 characters,
'' and file names must be less than 260 characters.
''
'' T:System.PlatformNotSupportedException:
'' The current operating system is not Windows NT or later.
'<SecuritySafeCritical>
'Public Sub New(path As String, mode As FileMode, rights As FileSystemRights, share As FileShare, bufferSize As Integer, options As FileOptions, fileSecurity As FileSecurity)
'End Sub
''' <summary>
''' Gets a value indicating whether the current stream supports reading.
''' </summary>
''' <returns>true if the stream supports reading; false if the stream is closed or was opened
''' with write-only access.</returns>
PublicOverridesReadOnlyPropertyCanReadAsBoolean
Get
ReturnInfo.CanRead
EndGet
EndProperty
''' <summary>
''' Gets a value indicating whether the current stream supports seeking.
''' </summary>
''' <returns>true if the stream supports seeking; false if the stream is closed or if the
''' FileStream was constructed from an operating-system handle such as a pipe or
''' output to the console.</returns>
PublicOverridesReadOnlyPropertyCanSeekAsBoolean
Get
ReturnInfo.CanSeek
EndGet
EndProperty
''' <summary>
''' Gets a value indicating whether the current stream supports writing.
''' </summary>
''' <returns>true if the stream supports writing; false if the stream is closed or was opened
''' with read-only access.</returns>
PublicOverridesReadOnlyPropertyCanWriteAsBoolean
Get
ReturnInfo.CanWrite
EndGet
EndProperty
' Exceptions:
' T:System.Security.SecurityException:
' The caller does not have the required permission.
''' <summary>
''' Gets the operating system file handle for the file that the current FileStream
''' object encapsulates.
''' </summary>
''' <returns>The operating system file handle for the file encapsulated by this FileStream
''' object, or -1 if the FileStream has been closed.</returns>
<Obsolete("This property has been deprecated. Please use FileStream's SafeFileHandle property instead. http://go.microsoft.com/fwlink/?linkid=14202")>
PublicOverridableReadOnlyPropertyHandleAsIntPtr
Get
ReturnInfo.FileHandle
EndGet
EndProperty
''' <summary>
''' Gets a value indicating whether the FileStream was opened asynchronously or synchronously.
''' </summary>
''' <returns>true if the FileStream was opened asynchronously; otherwise, false.</returns>
PublicOverridableReadOnlyPropertyIsAsyncAsBoolean
Get
ReturnInfo.IsAsync
EndGet
EndProperty
' Exceptions:
' T:System.NotSupportedException:
' System.IO.FileStream.CanSeek for this stream is false.
'
' T:System.IO.IOException:
' An I/O error, such as the file being closed, occurred.
''' <summary>
''' Gets the length in bytes of the stream.
''' </summary>
''' <returns>A long value representing the length of the stream in bytes.</returns>
' This System.IAsyncResult object was not created by calling System.IO.Stream.BeginWrite(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)
' on this class.
'
' T:System.InvalidOperationException:
' System.IO.FileStream.EndWrite(System.IAsyncResult) is called multiple times.
'
' T:System.IO.IOException:
' The stream is closed or an internal error has occurred.
''' <summary>
''' Ends an asynchronous write operation and blocks until the I/O operation is complete.
''' (Consider using System.IO.FileStream.WriteAsync(System.Byte[],System.Int32,System.Int32,System.Threading.CancellationToken)
' The array length minus offset is less than numBytes.
'
' T:System.ArgumentNullException:
' array is null.
'
' T:System.ArgumentOutOfRangeException:
' offset or numBytes is negative.
'
' T:System.IO.IOException:
' An asynchronous read was attempted past the end of the file.
''' <summary>
''' Begins an asynchronous read operation. (Consider using System.IO.FileStream.ReadAsync(System.Byte[],System.Int32,System.Int32,System.Threading.CancellationToken)
''' instead; see the Remarks section.)
''' </summary>
''' <param name="array">The buffer to read data into.</param>
''' <param name="offset">The byte offset in array at which to begin reading.</param>
''' <param name="numBytes">The maximum number of bytes to read.</param>
''' <param name="userCallback">The method to be called when the asynchronous read operation is completed.</param>
''' <param name="stateObject">A user-provided object that distinguishes this particular asynchronous read request
''' from other requests.</param>
''' <returns>An object that references the asynchronous read.</returns>
' array length minus offset is less than numBytes.
'
' T:System.ArgumentNullException:
' array is null.
'
' T:System.ArgumentOutOfRangeException:
' offset or numBytes is negative.
'
' T:System.NotSupportedException:
' The stream does not support writing.
'
' T:System.ObjectDisposedException:
' The stream is closed.
'
' T:System.IO.IOException:
' An I/O error occurred.
''' <summary>
''' Begins an asynchronous write operation. (Consider using System.IO.FileStream.WriteAsync(System.Byte[],System.Int32,System.Int32,System.Threading.CancellationToken)
''' instead; see the Remarks section.)
''' </summary>
''' <param name="array">The buffer containing data to write to the current stream.</param>
''' <param name="offset">The zero-based byte offset in array at which to begin copying bytes to the current
''' stream.</param>
''' <param name="numBytes">The maximum number of bytes to write.</param>
''' <param name="userCallback">The method to be called when the asynchronous write operation is completed.</param>
''' <param name="stateObject">A user-provided object that distinguishes this particular asynchronous write
''' request from other requests.</param>
''' <returns>An object that references the asynchronous write.</returns>
' This System.IAsyncResult object was not created by calling System.IO.FileStream.BeginRead(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)
' on this class.
'
' T:System.InvalidOperationException:
' System.IO.FileStream.EndRead(System.IAsyncResult) is called multiple times.
'
' T:System.IO.IOException:
' The stream is closed or an internal error has occurred.
''' <summary>
''' Waits for the pending asynchronous read operation to complete. (Consider using