write(_:count:)

Writes the contents of a buffer at the current file offset.

FileDescriptor.swift:401
@discardableResult func write(_ buffer: [UInt8], count: Int? = nil) throws(Errno) -> Int

Parameters

buffer

REQUIRED The region of memory that contains the data being written.

count

OPTIONAL The bytes you want to read.

Returns

The number of bytes that were written.