{ return rpmdb2solvAttr( "register.release", _root ); }
std::string TargetImpl::distributionVersion() const
- { return rpmdb2solvAttr( "releasever", _root ); }
+ {
+ if ( _distributionVersion.empty() )
+ {
+ _distributionVersion = rpmdb2solvAttr( "releasever", _root );
+ if ( !_distributionVersion.empty() )
+ MIL << "Remember distributionVersion = '" << _distributionVersion << "'" << endl;
+ }
+ return _distributionVersion;
+ }
///////////////////////////////////////////////////////////////////
/** \copydoc Target::targetDistributionRelease()*/
std::string targetDistributionRelease() const;
-
+
/** \copydoc Target::distributionVersion()*/
std::string distributionVersion() const;
SoftLocksFile _softLocksFile;
/** Hard-Locks database */
HardLocksFile _hardLocksFile;
+ /** Cache distributionVersion */
+ mutable std::string _distributionVersion;
private:
/** Null implementation */
static TargetImpl_Ptr _nullimpl;