* download progress indicator's overall statistics.
*/
bool Local;
+ string UsedMirror;
/** \brief The number of fetch queues into which this item has been
* inserted.
/** \return \b true if this object is being fetched from a trusted source. */
virtual bool IsTrusted() {return false;};
+
+ // report mirror problems
+ /** \brief Report mirror problem
+ *
+ * This allows reporting mirror failures back to a centralized
+ * server. The apt-report-mirror-failure script is called for this
+ *
+ * \param FailCode A short failure string that is send
+ */
+ void ReportMirrorFailure(string FailCode);
+
/** \brief Initialize an item.
*
pkgAcquire::MethodConfig *Cnf);
virtual string Custom600Headers();
virtual string DescURI() {return RealURI + CompressionExtension;};
+ virtual string HashSum() {return ExpectedHash.toStr(); };
/** \brief Create a pkgAcqIndex.
*
* (".bz2" is used if bzip2 is installed, ".gz" otherwise).
*/
pkgAcqIndex(pkgAcquire *Owner,string URI,string URIDesc,
- string ShortDesc, HashString ExpectedHash, string compressExt="");
+ string ShortDesc, HashString ExpectedHash,
+ string compressExt="");
};
/** \brief An acquire item that is responsible for fetching a
pkgRecords *Recs;
/** \brief The hashsum of this package. */
- HashString hash;
+ HashString ExpectedHash;
/** \brief A location in which the actual filename of the package
* should be stored.
virtual string DescURI() {return Desc.URI;};
virtual string ShortDesc() {return Desc.ShortDesc;};
virtual void Finished();
- virtual string HashSum() {return hash.toStr(); };
+ virtual string HashSum() {return ExpectedHash.toStr(); };
virtual bool IsTrusted();
/** \brief Create a new pkgAcqArchive.
pkgAcquire::ItemDesc Desc;
/** \brief The hashsum of the file to download, if it is known. */
- HashString hash;
+ HashString ExpectedHash;
/** \brief How many times to retry the download, set from
* Acquire::Retries.
virtual void Failed(string Message,pkgAcquire::MethodConfig *Cnf);
virtual void Done(string Message,unsigned long Size,string CalcHash,
pkgAcquire::MethodConfig *Cnf);
- virtual string HashSum() {return hash.toStr(); };
virtual string DescURI() {return Desc.URI;};
+ virtual string HashSum() {return ExpectedHash.toStr(); };
/** \brief Create a new pkgAcqFile object.
*