[#BloombergLP-bdls-FilesystemUtil-write]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdls.adoc[bdls]::xref:BloombergLP/bdls/FilesystemUtil.adoc[FilesystemUtil]::write
:relfileprefix: ../../../
:mrdocs:

Write the specified `numBytes` from the specified `buffer` address to the file with the specified `descriptor`&period; Return `numBytes` on success&semi; the number of bytes written if space was exhausted&semi; or a negative value on some other error&period;

== Synopsis

Declared in `&lt;bdls&lowbar;filesystemutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
int
write(
    xref:BloombergLP/bdls/FilesystemUtil/FileDescriptor.adoc[FileDescriptor] descriptor,
    void const* buffer,
    int numBytes);
----


[.small]#Created with https://www.mrdocs.com[MrDocs]#
