• Home
  • API Documentation
Show / Hide Table of Contents
  • McStreamy
    • ByteArrayExtensions
      • ToStream
    • NonClosingStreamAdapter
      • CanRead
      • CanSeek
      • CanTimeout
      • CanWrite
      • Dispose
      • Flush
      • Length
      • NonClosingStreamAdapter
      • Position
      • Read
      • ReadByte
      • ReadTimeout
      • Seek
      • SetLength
      • ToString
      • Write
      • WriteByte
      • WriteTimeout
    • StreamExtensions
      • ReadAllBytes
      • ReadAllBytesAsync
      • ReadAsString
      • ReadAsStringAsync
      • WriteAllBytes
      • WriteAllBytesAsync
    • StringExtensions
      • ToStream

Method WriteAllBytes

WriteAllBytes(Stream, Byte[])

Writes all bytes in the specified byte array to the stream.

Declaration
public static void WriteAllBytes(this Stream stream, byte[] data)
Parameters
Type Name Description
System.IO.Stream stream

The stream.

System.Byte[] data

The bytes to be written.

Exceptions
Type Condition
System.ArgumentNullException

Thrown if data or stream is null.

Back to top Copyright (c) 2017 Troy Willmot