diff --git a/docs/Makefile.am b/docs/Makefile.am index e16ee3e..b3fc26b 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -1,4 +1,4 @@ -# $Id: Makefile.am,v 1.19 2007/06/14 15:45:03 jehousley Exp $ +# $Id: Makefile.am,v 1.20 2007/06/14 16:08:43 jehousley Exp $ EXTRA_DIST = template.3 @@ -40,8 +40,12 @@ dist_man_MANS = libssh2_poll_channel_read.3 \ libssh2_sftp_close_handle.3 \ libssh2_sftp_fstat_ex.3 \ + libssh2_sftp_last_error.3 \ libssh2_sftp_init.3 \ libssh2_sftp_open_ex.3 \ libssh2_sftp_mkdir_ex.3 \ libssh2_sftp_read.3 \ - libssh2_sftp_readdir.3 + libssh2_sftp_readdir.3 \ + libssh2_sftp_rename_ex.3 \ + libssh2_sftp_rmdir_ex.3 \ + libssh2_sftp_seek.3 diff --git a/docs/libssh2_sftp_last_error.3 b/docs/libssh2_sftp_last_error.3 new file mode 100644 index 0000000..725262a --- /dev/null +++ b/docs/libssh2_sftp_last_error.3 @@ -0,0 +1,23 @@ +.\" $Id: libssh2_sftp_last_error.3,v 1.1 2007/06/14 16:08:43 jehousley Exp $ +.\" +.TH libssh2_sftp_last_error 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual" +.SH NAME +libssh2_sftp_last_error - return the last SFTP-specific error code +.SH SYNOPSIS +#include +#include + +unsigned long +libssh2_sftp_last_error(LIBSSH2_SFTP *sftp); + +.SH DESCRIPTION +\fIsftp\fP - SFTP instance as returned by +.BR libssh2_sftp_init(3) + +Determines the last error code produced by the SFTP layer. + +.SH RETURN VALUE +Current error code state of the SFTP instance. + +.SH SEE ALSO +.BR libssh2_sftp_init(3) diff --git a/docs/libssh2_sftp_rename_ex.3 b/docs/libssh2_sftp_rename_ex.3 new file mode 100644 index 0000000..4277e48 --- /dev/null +++ b/docs/libssh2_sftp_rename_ex.3 @@ -0,0 +1,58 @@ +.\" $Id: libssh2_sftp_rename_ex.3,v 1.1 2007/06/14 16:08:43 jehousley Exp $ +.\" +.TH libssh2_sftp_rename_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual" +.SH NAME +libssh2_sftp_rename_ex - rename a file +.SH SYNOPSIS +#include +#include + +int +libssh2_sftp_rename_ex(LIBSSH2_SFTP *sftp, const char *source_filename, unsigned int source_filename_len, const char *dest_filename, unsigned int dest_filename_len, long flags); + +int +libssh2_sftp_rename_ex(LIBSSH2_SFTP *sftp, const char *source_filename, const char *dest_filename); + +.SH DESCRIPTION +\fIsftp\fP - SFTP instance as returned by +.BR libssh2_sftp_init(3) + +\fIsourcefile\fP - Path and name of the existing filesystem entry + +\fIsourcefile_len\fP - Length of the path and name of the existing +filesystem entry + +\fIdestfile\fP - Path and name of the target filesystem entry + +\fIdestfile_len\fP - Length of the path and name of the target +filesystem entry + +\fIflags\fP - +Bitmask flags made up of LIBSSH2_SFTP_RENAME_* constants. + +Rename a filesystem object on the remote filesystem. The semantics of +this command typically include the ability to move a filsystem object +between folders and/or filesystem mounts. If the LIBSSH2_SFTP_RENAME_OVERWRITE +flag is not set and the destfile entry already exists, the operation +will fail. Use of the other two flags indicate a preference (but not a +requirement) for the remote end to perform an atomic rename operation +and/or using native system calls when possible. + +.SH RETURN VALUE +Return 0 on success or negative on failure. It returns +LIBSSH2_ERROR_EAGAIN when it would otherwise block. While +LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se. + +.SH ERRORS +\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed. + +\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket. + +\fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP - + +\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was +received on the socket, or an SFTP operation caused an errorcode to +be returned by the server. + +.SH SEE ALSO +.BR libssh2_sftp_init(3) diff --git a/docs/libssh2_sftp_rmdir_ex.3 b/docs/libssh2_sftp_rmdir_ex.3 new file mode 100644 index 0000000..5e5bf21 --- /dev/null +++ b/docs/libssh2_sftp_rmdir_ex.3 @@ -0,0 +1,43 @@ +.\" $Id: libssh2_sftp_rmdir_ex.3,v 1.1 2007/06/14 16:08:43 jehousley Exp $ +.\" +.TH libssh2_sftp_rmdir_ex 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual" +.SH NAME +libssh2_sftp_rmdir_ex - rename a file +.SH SYNOPSIS +#include +#include + +int +libssh2_sftp_rmdir_ex(LIBSSH2_SFTP *sftp, const char *path, unsigned int path_len); + +int +libssh2_sftp_rmdir_ex(LIBSSH2_SFTP *sftp, const char *path); + +.SH DESCRIPTION +\fIsftp\fP - SFTP instance as returned by +.BR libssh2_sftp_init(3) + +\fIsourcefile\fP - Full path of the existing directory to remove. + +\fIsourcefile_len\fP - Length of the full path of the existing directory to remove. + +Remove a directory from the remote file system. + +.SH RETURN VALUE +Return 0 on success or negative on failure. It returns +LIBSSH2_ERROR_EAGAIN when it would otherwise block. While +LIBSSH2_ERROR_EAGAIN is a negative number, it isn't really a failure per se. + +.SH ERRORS +\fILIBSSH2_ERROR_ALLOC\fP - An internal memory allocation call failed. + +\fILIBSSH2_ERROR_SOCKET_SEND\fP - Unable to send data on socket. + +\fILIBSSH2_ERROR_SOCKET_TIMEOUT\fP - + +\fILIBSSH2_ERROR_SFTP_PROTOCOL\fP - An invalid SFTP protocol response was +received on the socket, or an SFTP operation caused an errorcode to +be returned by the server. + +.SH SEE ALSO +.BR libssh2_sftp_init(3) diff --git a/docs/libssh2_sftp_seek.3 b/docs/libssh2_sftp_seek.3 new file mode 100644 index 0000000..62eaeb9 --- /dev/null +++ b/docs/libssh2_sftp_seek.3 @@ -0,0 +1,26 @@ +.\" $Id: libssh2_sftp_seek.3,v 1.1 2007/06/14 16:08:43 jehousley Exp $ +.\" +.TH libssh2_sftp_seek 3 "1 Jun 2007" "libssh2 0.15" "libssh2 manual" +.SH NAME +libssh2_sftp_seek - set the read/write position indicator within a file +.SH SYNOPSIS +#include +#include + +void +libssh2_sftp_seek(LIBSSH2_SFTP_HANDLE *handle, size_t offset); + +.SH DESCRIPTION +\fIhandle\fP - SFTP File Handle as returned by +.BR libssh2_sftp_open(3) + +\fIoffset\fP - Number of bytes from the beginning of file to seek to. + +Move the file handle's internal pointer to an arbitrary location. +Note that libssh2 implements file pointers as a localized concept to make +file access appear more POSIX like. No packets are exchanged with the server +during a seek operation. The localized file pointer is simply used as a +convenience offset during read/write operations. + +.SH SEE ALSO +.BR libssh2_sftp_open(3)