12 #ifndef ZYPP_FETCHER_H
13 #define ZYPP_FETCHER_H
107 friend std::ostream &
operator<<( std::ostream & str,
251 bool recursive =
false,
295 bool recursive =
false,
319 void start(
const Pathname &dest_dir,
336 #endif // ZYPP_FETCHER_H
void setOptions(Options options)
Set the Fetcher options.
void addIndex(const OnMediaLocation &resource)
Adds an index containing metadata (for example checksums ) that will be retrieved and read before the...
Options options() const
Get current options.
Option
Various option flags to change behavior.
ZYPP_DECLARE_FLAGS(Options, Option)
void addCachePath(const Pathname &cache_dir)
adds a directory to the list of directories where to look for cached files
If a content file is found, it is downloaded and read.
void enqueueDigestedDir(const OnMediaLocation &resource, bool recursive=false, const FileChecker &checker=FileChecker())
Enqueue a directory and always check for checksums.
function< bool(const ProgressData &)> ReceiverFnc
Most simple version of progress reporting The percentage in most cases.
RWCOW_pointer< Impl > _pimpl
Pointer to implementation.
void enqueueDigested(const OnMediaLocation &resource, const FileChecker &checker=FileChecker(), const Pathname &deltafile=Pathname())
Enqueue a object for transferal, they will not be transfered until start() is called.
std::ostream & operator<<(std::ostream &str, const Exception &obj)
void reset()
Reset the transfer (jobs) list.
friend std::ostream & operator<<(std::ostream &str, const Fetcher &obj)
void start(const Pathname &dest_dir, MediaSetAccess &media, const ProgressData::ReceiverFnc &progress=ProgressData::ReceiverFnc())
start the transfer to a destination directory dest_dir You have to provde a media set access media to...
void enqueueDir(const OnMediaLocation &resource, bool recursive=false, const FileChecker &checker=FileChecker())
Enqueue a directory.
If a CHECKSUMS file is found, it is downloaded and read.
If a content or CHECKSUMS file is found, it is downloaded and read.
function< void(const Pathname &file)> FileChecker
Functor signature used to check files.
void enqueue(const OnMediaLocation &resource, const FileChecker &checker=FileChecker())
Enqueue a object for transferal, they will not be transfered until start() is called.
ZYPP_DECLARE_OPERATORS_FOR_FLAGS(FetcherJob::Flags)
This class allows to retrieve a group of files in a confortable way, providing some smartness that do...
RW_pointer supporting 'copy on write' functionality.