#include <zypp/media/MediaManager.h>
#include <zypp/MediaSetAccess.h>
#include <zypp/source/SUSEMediaVerifier.h>
-#include <zypp/source/OnMediaLocation.h>
+#include <zypp/nMediaLocation.h>
+#include <zypp/Fetcher.h>
#include "zypp/Product.h"
#include "zypp/Package.h"
using namespace std;
using namespace zypp;
using namespace media;
-using namespace source;
-
-class Fetcher
-{
-private:
- Url _url;
- Pathname _path;
- std::list<OnMediaLocation> _resources;
- std::list<Pathname> _caches;
-
-public:
-
- Fetcher( const Url &url, const Pathname &path )
- : _url(url), _path(path)
- {
-
- }
-
- void enqueue( const OnMediaLocation &resource )
- {
- _resources.push_back(resource);
- }
-
- void reset()
- {
- _resources.clear();
- _caches.clear();
- }
-
- /**
- * adds a directory to the list of directories
- * where to look for cached files
- */
- void insertCache( const Pathname &cache_dir )
- {
- _caches.push_back(cache_dir);
- }
-
- void start( const Pathname &dest_dir )
- {
- MediaSetAccess media(_url, _path);
-
- for ( list<OnMediaLocation>::const_iterator it_res = _resources.begin(); it_res != _resources.end(); ++it_res )
- {
- bool got_from_cache = false;
- for ( list<Pathname>::const_iterator it_cache = _caches.begin(); it_cache != _caches.end(); ++it_cache )
- {
- // Pathinfos could be cached to avoid too many stats?
- PathInfo info(*it_cache);
- if ( info.isDir() )
- {
- // does the current file exists in the current cache?
- Pathname cached_file = *it_cache + (*it_res).filename();
- if ( PathInfo( cached_file ).isExist() )
- {
- // check the checksum
- if ( is_checksum( cached_file, (*it_res).checksum() ) )
- {
- // cached
- MIL << "file " << (*it_res).filename() << " found in previous cache. Using cached copy." << endl;
- // checksum is already checked.
- // we could later implement double failover and try to download if file copy fails.
-
- // replicate the complete path in the target directory
- Pathname dest_full_path = dest_dir + (*it_res).filename();
- if ( assert_dir( dest_full_path.dirname() ) != 0 )
- ZYPP_THROW( Exception("Can't create " + dest_full_path.dirname().asString()));
-
- if ( filesystem::copy(cached_file, dest_full_path ) != 0 )
- { //copy_file2dir
- //ZYPP_THROW(SourceIOException("Can't copy " + cached_file.asString() + " to " + destination.asString()));
- ERR << "Can't copy " << cached_file + " to " + dest_dir << endl;
- // try next cache
- continue;
- }
-
- got_from_cache = true;
- break;
- }
- }
- else
- {
- // File exists in cache but with a different checksum
- // so just try next cache
- continue;
- }
- }
- else
- {
- // skip bad cache directory and try with next one
- ERR << "Skipping cache : " << *it_cache << endl;
- continue;
- }
- }
-
- if ( ! got_from_cache )
- {
- // try to get the file from the net
- try
- {
- Pathname tmp_file = media.provideFile(*it_res);
- Pathname dest_full_path = dest_dir + (*it_res).filename();
- if ( assert_dir( dest_full_path.dirname() ) != 0 )
- ZYPP_THROW( Exception("Can't create " + dest_full_path.dirname().asString()));
- if ( filesystem::copy(tmp_file, dest_full_path ) != 0 )
- {
- ZYPP_THROW( Exception("Can't copy " + tmp_file.asString() + " to " + dest_dir.asString()));
- }
- }
- catch (const Exception & excpt_r)
- {
- ZYPP_CAUGHT(excpt_r);
- ZYPP_THROW(SourceIOException("Can't provide " + (*it_res).filename().asString() + " : " + excpt_r.msg() ));
- }
- }
- else
- {
- // We got the file from cache
- // continue with next file
- continue;
- }
- }
- }
-// callback::SendReport<DigestReport> report;
-// if ( checksum.empty() )
-// {
-// MIL << "File " << file_url << " has no checksum available." << std::endl;
-// if ( report->askUserToAcceptNoDigest(file_to_download) )
-// {
-// MIL << "User accepted " << file_url << " with no checksum." << std::endl;
-// return;
-// }
-// else
-// {
-// ZYPP_THROW(SourceMetadataException( file_url.asString() + " " + N_(" miss checksum.") ));
-// }
-// }
-// else
-// {
-// if (! is_checksum( destination, checksum))
-// ZYPP_THROW(SourceMetadataException( file_url.asString() + " " + N_(" fails checksum verification.") ));
-// }
-
-};
+//using namespace source;
class SUSETagsDownloader
{
Signature.cc
KeyRing.cc
MediaSetAccess.cc
- ProvideFilePolicy.cc
+ ProvideFilePolicy.cc
+ OnMediaLocation.cc
+ Fetcher.cc
)
SET( zypp_HEADERS
DiskUsageCounter.h
Edition.h
ExternalProgram.h
+ Fetcher.h
KVMap.h
KeyRing.h
Language.h
NVRAD.h
NameKindProxy.h
NeedAType.h
+ OnMediaLocation.h
Package.h
Patch.h
PathInfo.h
SET( zypp_source_SRCS
source/Applydeltarpm.cc
source/MediaSet.cc
- source/OnMediaLocation.cc
source/PackageDelta.cc
source/PackageProvider.cc
source/SourceImpl.cc
source/Applydeltarpm.h
source/Builtin.h
source/MediaSet.h
- source/OnMediaLocation.h
source/PackageDelta.h
source/PackageProvider.h
source/SourceImpl.h
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+
+#include "zypp/base/Logger.h"
+#include "zypp/Fetcher.h"
+#include "zypp/MediaSetAccess.h"
+#include "zypp/PathInfo.h"
+
+using namespace std;
+using namespace zypp::filesystem;
+
+namespace zypp
+{
+
+Fetcher::Fetcher( const Url &url, const Pathname &path )
+ : _url(url), _path(path)
+{
+
+}
+
+void Fetcher::enqueue( const OnMediaLocation &resource )
+{
+ _resources.push_back(resource);
+}
+
+void Fetcher::reset()
+{
+ _resources.clear();
+ _caches.clear();
+}
+
+void Fetcher::insertCache( const Pathname &cache_dir )
+{
+ _caches.push_back(cache_dir);
+}
+
+void Fetcher::start( const Pathname &dest_dir )
+{
+ MediaSetAccess media(_url, _path);
+
+ for ( list<OnMediaLocation>::const_iterator it_res = _resources.begin(); it_res != _resources.end(); ++it_res )
+ {
+ bool got_from_cache = false;
+ for ( list<Pathname>::const_iterator it_cache = _caches.begin(); it_cache != _caches.end(); ++it_cache )
+ {
+ // Pathinfos could be cached to avoid too many stats?
+ PathInfo info(*it_cache);
+ if ( info.isDir() )
+ {
+ // does the current file exists in the current cache?
+ Pathname cached_file = *it_cache + (*it_res).filename();
+ if ( PathInfo( cached_file ).isExist() )
+ {
+ // check the checksum
+ if ( is_checksum( cached_file, (*it_res).checksum() ) )
+ {
+ // cached
+ MIL << "file " << (*it_res).filename() << " found in previous cache. Using cached copy." << endl;
+ // checksum is already checked.
+ // we could later implement double failover and try to download if file copy fails.
+
+ // replicate the complete path in the target directory
+ Pathname dest_full_path = dest_dir + (*it_res).filename();
+ if ( assert_dir( dest_full_path.dirname() ) != 0 )
+ ZYPP_THROW( Exception("Can't create " + dest_full_path.dirname().asString()));
+
+ if ( filesystem::copy(cached_file, dest_full_path ) != 0 )
+ { //copy_file2dir
+ //ZYPP_THROW(SourceIOException("Can't copy " + cached_file.asString() + " to " + destination.asString()));
+ ERR << "Can't copy " << cached_file + " to " + dest_dir << endl;
+ // try next cache
+ continue;
+ }
+
+ got_from_cache = true;
+ break;
+ }
+ }
+ else
+ {
+ // File exists in cache but with a different checksum
+ // so just try next cache
+ continue;
+ }
+ }
+ else
+ {
+ // skip bad cache directory and try with next one
+ ERR << "Skipping cache : " << *it_cache << endl;
+ continue;
+ }
+ }
+
+ if ( ! got_from_cache )
+ {
+ // try to get the file from the net
+ try
+ {
+ Pathname tmp_file = media.provideFile(*it_res);
+ Pathname dest_full_path = dest_dir + (*it_res).filename();
+ if ( assert_dir( dest_full_path.dirname() ) != 0 )
+ ZYPP_THROW( Exception("Can't create " + dest_full_path.dirname().asString()));
+ if ( filesystem::copy(tmp_file, dest_full_path ) != 0 )
+ {
+ ZYPP_THROW( Exception("Can't copy " + tmp_file.asString() + " to " + dest_dir.asString()));
+ }
+ }
+ catch (const Exception & excpt_r)
+ {
+ ZYPP_CAUGHT(excpt_r);
+ ZYPP_THROW(Exception("Can't provide " + (*it_res).filename().asString() + " : " + excpt_r.msg() ));
+ }
+ }
+ else
+ {
+ // We got the file from cache
+ // continue with next file
+ continue;
+ }
+ }
+}
+// callback::SendReport<DigestReport> report;
+// if ( checksum.empty() )
+// {
+// MIL << "File " << file_url << " has no checksum available." << std::endl;
+// if ( report->askUserToAcceptNoDigest(file_to_download) )
+// {
+// MIL << "User accepted " << file_url << " with no checksum." << std::endl;
+// return;
+// }
+// else
+// {
+// ZYPP_THROW(SourceMetadataException( file_url.asString() + " " + N_(" miss checksum.") ));
+// }
+// }
+// else
+// {
+// if (! is_checksum( destination, checksum))
+// ZYPP_THROW(SourceMetadataException( file_url.asString() + " " + N_(" fails checksum verification.") ));
+// }
+
+} // namespace zypp
\ No newline at end of file
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+
+#ifndef ZYPP_FETCHER_H
+#define ZYPP_FETCHER_H
+
+#include <list>
+#include "zypp/Pathname.h"
+#include "zypp/Url.h"
+#include "zypp/OnMediaLocation.h"
+
+namespace zypp
+{
+
+ /**
+ * Edition represents <code>[epoch:]version[-release]</code>
+ *
+ * This class allows to retrieve a group of files which can
+ * be cached already on the local disk.
+ *
+ * \code
+ * Fetcher fetcher(url, path);
+ * fetcher.enqueue( OnMediaLocation().filename("/content") );
+ * fetcher.insertCache("/tmp/cache")
+ * fetcher.start( "/download-dir );
+ * fetcher.reset();
+ * \endcode
+ */
+ class Fetcher
+ {
+ public:
+ /**
+ * Constructs a fetcher from a url and path
+ */
+ Fetcher( const Url &url, const Pathname &path );
+
+ /**
+ * Enqueue a object for transferal, they will not
+ * be transfered until \ref start() is called
+ */
+ void enqueue( const OnMediaLocation &resource );
+ /**
+ * adds a directory to the list of directories
+ * where to look for cached files
+ */
+ void insertCache( const Pathname &cache_dir );
+ /**
+ * Reset the transfer list and cache list
+ */
+ void reset();
+ /**
+ * start the transfer to a destination directory
+ * The file tree will be replicated inside this
+ * directory
+ */
+ void start( const Pathname &dest_dir );
+
+ private:
+ Url _url;
+ Pathname _path;
+ std::list<OnMediaLocation> _resources;
+ std::list<Pathname> _caches;
+ };
+
+} // ns zypp
+#endif
\ No newline at end of file
}
}
- Pathname MediaSetAccess::provideFile( const source::OnMediaLocation & on_media_file )
+ Pathname MediaSetAccess::provideFile( const OnMediaLocation & on_media_file )
{
return provideFile( on_media_file.filename(), on_media_file.medianr() );
}
#include "zypp/media/MediaManager.h"
#include "zypp/Pathname.h"
#include "zypp/CheckSum.h"
-#include "zypp/source/OnMediaLocation.h"
+#include "zypp/OnMediaLocation.h"
///////////////////////////////////////////////////////////////////
namespace zypp
//
// CLASS NAME : SourceCache
//
+ /**
+ * The
+ */
class MediaSetAccess : public base::ReferenceCounted, private base::NonCopyable
{
friend std::ostream & operator<<( std::ostream & str, const MediaSetAccess & obj );
/**
* provide a file fom a multiple media
*/
- Pathname provideFile( const source::OnMediaLocation & on_media_file );
+ Pathname provideFile( const OnMediaLocation & on_media_file );
/**
* provides a file on multiple media which is possibly cached
* if they match, the cached one is copied to the destination directory
* if not the file is provided and copied to the destination directory.
*/
- void providePossiblyCachedMetadataFile( const source::OnMediaLocation &file_on_media, const Pathname &destination, const Pathname &cached_file);
+ void providePossiblyCachedMetadataFile( const OnMediaLocation &file_on_media, const Pathname &destination, const Pathname &cached_file);
Pathname provideFile(const Pathname & file, unsigned media_nr = 1 );
Pathname provideFile(const Pathname & file, unsigned media_nr, const FileChecker checker );
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+/** \file zypp/source/OnMediaLocation.cc
+ *
+*/
+#include <iostream>
+//#include "zypp/base/Logger.h"
+
+#include "zypp/OnMediaLocation.h"
+
+using std::endl;
+
+///////////////////////////////////////////////////////////////////
+namespace zypp
+{ /////////////////////////////////////////////////////////////////
+///////////////////////////////////////////////////////////////////
+ /******************************************************************
+ **
+ ** FUNCTION NAME : operator<<
+ ** FUNCTION TYPE : std::ostream &
+ */
+ std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj )
+ {
+ return str << "[" << obj.medianr() << "]" << obj.filename()
+ << "{" << obj.downloadsize() << "|" << obj.checksum() << "}";
+ }
+
+/////////////////////////////////////////////////////////////////
+} // namespace zypp
+///////////////////////////////////////////////////////////////////
--- /dev/null
+/*---------------------------------------------------------------------\
+| ____ _ __ __ ___ |
+| |__ / \ / / . \ . \ |
+| / / \ V /| _/ _/ |
+| / /__ | | | | | | |
+| /_____||_| |_| |_| |
+| |
+\---------------------------------------------------------------------*/
+/** \file zypp/source/OnMediaLocation.h
+ *
+*/
+#ifndef ZYPP_SOURCE_ONMEDIALOCATION_H
+#define ZYPP_SOURCE_ONMEDIALOCATION_H
+
+#include <iosfwd>
+
+#include "zypp/Pathname.h"
+#include "zypp/ByteCount.h"
+#include "zypp/CheckSum.h"
+
+///////////////////////////////////////////////////////////////////
+namespace zypp
+{ /////////////////////////////////////////////////////////////////
+
+ ///////////////////////////////////////////////////////////////////
+ //
+ // CLASS NAME : OnMediaLocation
+ //
+ /**
+ * Describes a path ona certain media amongs as the information
+ * required to download it, like its media number, checksum and
+ * size.
+ * it does not specifies the URI of the file.
+ */
+ class OnMediaLocation
+ {
+ friend std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj );
+
+ public:
+ /** Ctor */
+ OnMediaLocation()
+ : _medianr( 1 )
+ {}
+
+ public:
+ unsigned medianr() const { return _medianr; }
+ const Pathname & filename() const { return _filename; }
+ const CheckSum & checksum() const { return _checksum; }
+ const ByteCount & downloadsize() const { return _downloadsize; }
+
+ public:
+ OnMediaLocation & medianr( unsigned val_r ) { _medianr = val_r; return *this; }
+ OnMediaLocation & filename( const Pathname & val_r ) { _filename = val_r; return *this; }
+ OnMediaLocation & checksum( const CheckSum & val_r ) { _checksum = val_r; return *this; }
+ OnMediaLocation & downloadsize( const ByteCount & val_r ) { _downloadsize = val_r; return *this; }
+
+ private:
+ unsigned _medianr;
+ Pathname _filename;
+ CheckSum _checksum;
+ ByteCount _downloadsize;
+ };
+ ///////////////////////////////////////////////////////////////////
+
+ /** \relates OnMediaLocation Stream output */
+ std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj );
+
+ /////////////////////////////////////////////////////////////////
+} // namespace zypp
+///////////////////////////////////////////////////////////////////
+#endif // ZYPP_SOURCE_ONMEDIALOCATION_H
+++ /dev/null
-/*---------------------------------------------------------------------\
-| ____ _ __ __ ___ |
-| |__ / \ / / . \ . \ |
-| / / \ V /| _/ _/ |
-| / /__ | | | | | | |
-| /_____||_| |_| |_| |
-| |
-\---------------------------------------------------------------------*/
-/** \file zypp/source/OnMediaLocation.cc
- *
-*/
-#include <iostream>
-//#include "zypp/base/Logger.h"
-
-#include "zypp/source/OnMediaLocation.h"
-
-using std::endl;
-
-///////////////////////////////////////////////////////////////////
-namespace zypp
-{ /////////////////////////////////////////////////////////////////
- ///////////////////////////////////////////////////////////////////
- namespace source
- { /////////////////////////////////////////////////////////////////
-
- /******************************************************************
- **
- ** FUNCTION NAME : operator<<
- ** FUNCTION TYPE : std::ostream &
- */
- std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj )
- {
- return str << "[" << obj.medianr() << "]" << obj.filename()
- << "{" << obj.downloadsize() << "|" << obj.checksum() << "}";
- }
-
- /////////////////////////////////////////////////////////////////
- } // namespace source
- ///////////////////////////////////////////////////////////////////
- /////////////////////////////////////////////////////////////////
-} // namespace zypp
-///////////////////////////////////////////////////////////////////
+++ /dev/null
-/*---------------------------------------------------------------------\
-| ____ _ __ __ ___ |
-| |__ / \ / / . \ . \ |
-| / / \ V /| _/ _/ |
-| / /__ | | | | | | |
-| /_____||_| |_| |_| |
-| |
-\---------------------------------------------------------------------*/
-/** \file zypp/source/OnMediaLocation.h
- *
-*/
-#ifndef ZYPP_SOURCE_ONMEDIALOCATION_H
-#define ZYPP_SOURCE_ONMEDIALOCATION_H
-
-#include <iosfwd>
-
-#include "zypp/Pathname.h"
-#include "zypp/ByteCount.h"
-#include "zypp/CheckSum.h"
-
-///////////////////////////////////////////////////////////////////
-namespace zypp
-{ /////////////////////////////////////////////////////////////////
- ///////////////////////////////////////////////////////////////////
- namespace source
- { /////////////////////////////////////////////////////////////////
-
- ///////////////////////////////////////////////////////////////////
- //
- // CLASS NAME : OnMediaLocation
- //
- /**
- * Describes a path ona certain media amongs as the information
- * required to download it, like its media number, checksum and
- * size.
- * it does not specifies the URI of the file.
- */
- class OnMediaLocation
- {
- friend std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj );
-
- public:
- /** Ctor */
- OnMediaLocation()
- : _medianr( 1 )
- {}
-
- public:
- unsigned medianr() const { return _medianr; }
- const Pathname & filename() const { return _filename; }
- const CheckSum & checksum() const { return _checksum; }
- const ByteCount & downloadsize() const { return _downloadsize; }
-
- public:
- OnMediaLocation & medianr( unsigned val_r ) { _medianr = val_r; return *this; }
- OnMediaLocation & filename( const Pathname & val_r ) { _filename = val_r; return *this; }
- OnMediaLocation & checksum( const CheckSum & val_r ) { _checksum = val_r; return *this; }
- OnMediaLocation & downloadsize( const ByteCount & val_r ) { _downloadsize = val_r; return *this; }
-
- private:
- unsigned _medianr;
- Pathname _filename;
- CheckSum _checksum;
- ByteCount _downloadsize;
- };
- ///////////////////////////////////////////////////////////////////
-
- /** \relates OnMediaLocation Stream output */
- std::ostream & operator<<( std::ostream & str, const OnMediaLocation & obj );
-
- /////////////////////////////////////////////////////////////////
- } // namespace source
- ///////////////////////////////////////////////////////////////////
- /////////////////////////////////////////////////////////////////
-} // namespace zypp
-///////////////////////////////////////////////////////////////////
-#endif // ZYPP_SOURCE_ONMEDIALOCATION_H
#include <iosfwd>
#include <list>
-#include "zypp/source/OnMediaLocation.h"
+#include "zypp/OnMediaLocation.h"
#include "zypp/Edition.h"
#include "zypp/Date.h"
//#include "zypp/Arch.h"
{}
public:
- const source::OnMediaLocation & location() const { return _location; }
+ const OnMediaLocation & location() const { return _location; }
const BaseVersions & baseversions() const { return _baseversions; }
const Date & buildtime() const { return _buildtime;}
public:
- PatchRpm & location( const source::OnMediaLocation & val_r ) { _location = val_r; return *this; }
+ PatchRpm & location( const OnMediaLocation & val_r ) { _location = val_r; return *this; }
PatchRpm & baseversions( const BaseVersions & val_r ) { _baseversions = val_r; return *this; }
PatchRpm & baseversion( const BaseVersion & val_r ) { _baseversions.push_back( val_r ); return *this; }
PatchRpm & buildtime( const Date & val_r ) { _buildtime = val_r; return *this; }
private:
- source::OnMediaLocation _location;
+ OnMediaLocation _location;
BaseVersions _baseversions;
Date _buildtime;
};
{}
public:
- const source::OnMediaLocation & location() const { return _location; }
+ const OnMediaLocation & location() const { return _location; }
const BaseVersion & baseversion() const { return _baseversion; }
const Date & buildtime() const { return _buildtime;}
public:
- DeltaRpm & location( const source::OnMediaLocation & val_r ) { _location = val_r; return *this; }
- DeltaRpm & baseversion( const BaseVersion & val_r ) { _baseversion = val_r; return *this; }
- DeltaRpm & buildtime( const Date & val_r ) { _buildtime = val_r; return *this; }
+ DeltaRpm & location( const OnMediaLocation & val_r ) { _location = val_r; return *this; }
+ DeltaRpm & baseversion( const BaseVersion & val_r ) { _baseversion = val_r; return *this; }
+ DeltaRpm & buildtime( const Date & val_r ) { _buildtime = val_r; return *this; }
private:
- source::OnMediaLocation _location;
+ OnMediaLocation _location;
BaseVersion _baseversion;
Date _buildtime;
};
// no patch/delta -> provide full package
ManagedFile ret;
- source::OnMediaLocation loc;
+ OnMediaLocation loc;
loc.medianr( _package->sourceMediaNr() )
.filename( _package->location() )
.checksum( _package->checksum() )
///////////////////////////////////////////////////////////////////
ManagedFile provideFile( Source_Ref source_r,
- const source::OnMediaLocation & loc_r,
+ const OnMediaLocation & loc_r,
const ProvideFilePolicy & policy_r )
{
MIL << "sourceProvideFile " << loc_r << endl;
#include "zypp/base/Functional.h"
#include "zypp/Source.h"
#include "zypp/ManagedFile.h"
-#include "zypp/source/OnMediaLocation.h"
+#include "zypp/OnMediaLocation.h"
#include "zypp/ProvideFilePolicy.h"
///////////////////////////////////////////////////////////////////
* \throws Exception
*/
ManagedFile provideFile( Source_Ref source_r,
- const source::OnMediaLocation & loc_r,
+ const OnMediaLocation & loc_r,
const ProvideFilePolicy & policy_r = ProvideFilePolicy() );
/////////////////////////////////////////////////////////////////
{
YUMPackageImpl::PatchRpm patch_rpm;
- patch_rpm.location( source::OnMediaLocation()
+ patch_rpm.location( OnMediaLocation()
.medianr( str::strtonum<unsigned>( it->media ) )
.filename( it->location )
.checksum( CheckSum( it->checksumType, it->checksum ) )
{
YUMPackageImpl::DeltaRpm delta_rpm;
- delta_rpm.location( source::OnMediaLocation()
+ delta_rpm.location( OnMediaLocation()
.medianr( str::strtonum<unsigned>( it->media ) )
.filename( it->location )
.checksum( CheckSum( it->checksumType, it->checksum ) )