.\" This manpage has been automatically generated by docbook2man
.\" from a DocBook document. This tool can be found at:
.\"
.\" Please send any bug reports, improvements, comments, patches,
.\" etc. to Steve Cheng .
.TH "GFS_PIO_WRITE" "3" "27 June 2010" "Gfarm" ""
.SH NAME
gfs_pio_write \- write to a file
.SH SYNOPSIS
.sp
\fB#include
.sp
gfarm_error_t gfs_pio_write (GFS_File \fIgf\fB, const void * \fIbuffer\fB, int \fIsize\fB, int * \fInp\fB);
\fR
.SH "DESCRIPTION"
.PP
\fBgfs_pio_write()\fR writes up to \fIsize\fR bytes to the file \fIgf\fR
from the buffer starting at \fIbuffer\fR\&. It returns the number of
bytes written to the address pointed by \fInp\fR\&.
.SH "RETURN VALUES"
.TP
\fBGFARM_ERR_NO_ERROR\fR
The function terminated successfully.
.TP
\fBGFARM_ERR_OPERATION_NOT_PERMITTED\fR
\fIgf\fR does not specify a regular file.
.TP
\fBGFARM_ERR_BAD_FILE_DESCRIPTOR\fR
The file descripter specified by \fIgfp\fR is
not a valid or is not open for writing.
.TP
\fBGFARM_ERR_NO_SPACE\fR
The file system node has no room to store data
.TP
\fBGFARM_ERR_NO_FILE_SYSTEM_NODE\fR
There is no available file system node.
.TP
\fBGFARM_ERR_NO_MEMORY\fR
Insufficient memory was available.
.TP
\fBOthers\fR
An error except the above occurred. The reason is shown by
\fBgfarm_error_string\fR(3)\&.
.SH "SEE ALSO"
.PP
\fBgfs_pio_create\fR(3),
\fBgfs_pio_flush\fR(3),
\fBgfs_pio_open\fR(3)