Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

transfer.h

Go to the documentation of this file.
00001 /* Copyright 2003 gnome-vfsmm Development Team
00002  *
00003  * This library is free software; you can redistribute it and/or
00004  * modify it under the terms of the GNU Library General Public
00005  * License as published by the Free Software Foundation; either
00006  * version 2 of the License, or (at your option) any later version.
00007  *
00008  * This library is distributed in the hope that it will be useful,
00009  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00010  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00011  * Library General Public License for more details.
00012  *
00013  * You should have received a copy of the GNU Library General Public
00014  * License along with this library; if not, write to the Free
00015  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00016  */
00017 
00018 
00019 #ifndef _LIBGNOMEVFSMM_TRANSFER_H
00020 #define _LIBGNOMEVFSMM_TRANSFER_H
00021 
00022 #include <glibmm.h>
00023 
00024 #include <libgnomevfsmm/enums.h>
00025 #include <libgnomevfsmm/exception.h>
00026 #include <libgnomevfsmm/uri.h>
00027 #include <libgnomevfsmm/transfer-progress.h>
00028 
00029 #include <libgnomevfs/gnome-vfs-xfer.h> //For GnomeVFSXferProgressInfo
00030 
00031 namespace Gnome
00032 {
00033 
00034 namespace Vfs
00035 {
00036 
00039 namespace Transfer
00040 {
00041 
00042 typedef Glib::ListHandle<Glib::ustring> ListHandleStrings;
00043 typedef Glib::ListHandle< Glib::RefPtr<const Uri> > ListHandleUris;
00044 
00045 //TODO: Find out what the return value is meant to be for.
00047 typedef sigc::slot<bool, const ProgressInfo&> SlotProgress;
00048 
00049 
00050 void transfer_list(const Glib::StringArrayHandle& source_uri_list, const Glib::StringArrayHandle& target_uri_list,
00051       TransferOptions options,
00052       ErrorMode error_mode,
00053       OverwriteMode overwrite_mode,
00054       const SlotProgress& slot);
00055       
00075 void transfer_list_uris(const ListHandleUris& source_uri_list, const ListHandleUris& target_uri_list,
00076       TransferOptions options = XFER_DEFAULT, //TODO: Does Default do anything useful?
00077       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00078       OverwriteMode overwrite_mode = XFER_OVERWRITE_MODE_ABORT,
00079       const SlotProgress& progress_callback = SlotProgress());
00080 
00081 void transfer(const Glib::ustring& source_uri, const Glib::ustring& target_uri,
00082       TransferOptions options = XFER_DEFAULT, //TODO: Does Default do anything useful?
00083       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00084       OverwriteMode overwrite_mode = XFER_OVERWRITE_MODE_ABORT,
00085       const SlotProgress& progress_callback = SlotProgress());
00086       
00087 void transfer(const Glib::RefPtr<const Uri>& source_uri, const Glib::RefPtr<const Uri>& target_uri,
00088       TransferOptions options = XFER_DEFAULT, //TODO: Does Default do anything useful?
00089       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00090       OverwriteMode overwrite_mode = XFER_OVERWRITE_MODE_ABORT,
00091       const SlotProgress& progress_callback = SlotProgress());
00092 
00093 //TODO: Add a string-based version of gnome_vfs_xfer_delete() to gnome-vfs.
00094 
00095 void remove(const Glib::ustring& source_uri,
00096       TransferOptions options = XFER_DEFAULT,
00097       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00098       const SlotProgress& progress_callback = SlotProgress());
00099       
00100 void remove(const Glib::RefPtr<const Uri>& source_uri,
00101       TransferOptions options = XFER_DEFAULT,
00102       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00103       const SlotProgress& progress_callback = SlotProgress());
00104 
00105 void remove_list(const Glib::StringArrayHandle& source_uri_list,
00106       TransferOptions options = XFER_DEFAULT,
00107       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00108       const SlotProgress& progress_callback = SlotProgress());
00109 
00110 void remove_list_uris(const ListHandleUris& source_uri_list,
00111       TransferOptions options = XFER_DEFAULT,
00112       ErrorMode error_mode = XFER_ERROR_MODE_ABORT,
00113       const SlotProgress& progress_callback = SlotProgress());
00114 
00115 } // namespace Transfer
00116 } // namespace Vfs
00117 } // namespace Gnome
00118 
00119 #endif /* _LIBGNOMEVFSMM_TRANSFER_H */

Generated on Wed Aug 17 17:31:33 2005 for libgnomevfsmm by  doxygen 1.3.9.1