15 #include <zypp/base/LogTools.h> 16 #include <zypp/base/IOStream.h> 17 #include <zypp/base/String.h> 19 #include <zypp/PathInfo.h> 20 #include <zypp/TmpPath.h> 21 #include <zypp/Date.h> 39 WAR <<
"Can't read " << pi << endl;
42 std::ifstream infile( file_r.
c_str() );
46 if ( ! l.empty() && l[0] !=
'#' )
51 MIL <<
"Read " << pi << endl;
63 std::set<IdString> sorted( data_r.begin(), data_r.end() );
64 dumpRange( outs, sorted.begin(), sorted.end(),
"#",
"\n",
"\n",
"\n",
"#\n" );
68 dumpRange( outs, data_r.begin(), data_r.end(),
"#",
"\n",
"\n",
"\n",
"#\n" );
bool next()
Advance to next line.
const Pathname & file() const
Return the file path.
int chmod(const Pathname &path, mode_t mode)
Like 'chmod'.
std::ostream & dumpRange(std::ostream &str, TIterator begin, TIterator end, const std::string &intro="{", const std::string &pfx="\ ", const std::string &sep="\ ", const std::string &sfx="\, const std::string &extro="}")
Print range defined by iterators (multiline style).
const char * c_str() const
String representation.
String related utilities and Regular expression matching.
Access to the sat-pools string space.
Simple lineparser: Traverse each line in a file.
std::string basename() const
Return the last component of this path.
Provide a new empty temporary file and delete it when no longer needed.
const Data & data() const
Return the data.
std::string trim(const std::string &s, const Trim trim_r)
int rename(const Pathname &oldpath, const Pathname &newpath)
Like 'rename'.
static void store(const Pathname &file_r, const Data &data_r)
Write Data to file_r.
std::ostream & operator<<(std::ostream &str, const CommitPackageCache &obj)
Save and restore a list of solvable names (ident IdString)
static Date now()
Return the current time.
static void load(const Pathname &file_r, Data &data_r)
Read Data from file_r.
Wrapper class for ::stat/::lstat.
static TmpFile makeSibling(const Pathname &sibling_r)
Provide a new empty temporary directory as sibling.
Easy-to use interface to the ZYPP dependency resolver.
std::unordered_set< IdString > Data
scoped_ptr< Data > _dataPtr