Export (0) Print
Expand All

Stream.AsyncWrite Extension Method (F#)

Returns an asynchronous computation that will write the given bytes to the stream.

Namespace/Module Path: Microsoft.FSharp.Control.CommonExtensions

Assembly: FSharp.Core (in FSharp.Core.dll)

// Signature:
type System.IO.Stream with
  member AsyncWrite : byte [] * ?int * ?int -> Async<unit>

// Usage:
stream.AsyncWrite (buffer)

buffer

Type: byte[]

The buffer to write from.

offset

Type: int

An optional offset as the number of bytes in the stream.

count

Type: int

An optional number of bytes to write to the stream.

Exception

Description

ArgumentException

Thrown when offset or count is longer than the buffer length.

Windows 7, Windows Vista SP2, Windows XP SP3, Windows XP x64 SP2, Windows Server 2008 R2, Windows Server 2008 SP2, Windows Server 2003 SP2

F# Runtime

Supported in: 2.0

Silverlight

Supported in: 3

Community Additions

ADD
Show:
© 2014 Microsoft