14 #ifndef ZYPP_POOLQUERYUTIL_TCC
15 #define ZYPP_POOLQUERYUTIL_TCC
35 template <
class OutputIterator>
40 std::ifstream fin( file.
c_str() );
60 template <
class InputIterator>
62 InputIterator begin, InputIterator end )
64 std::ofstream fout( file.
c_str(), std::ios_base::out | std::ios_base::trunc );
69 for_( it, begin, end )
71 it->serialize( fout );
78 #endif // ZYPP_POOLQUERYUTIL_H
#define ZYPP_THROW(EXCPT)
Drops a logline and throws the Exception.
void readPoolQueriesFromFile(const zypp::filesystem::Pathname &file, OutputIterator out)
sends to output iterator all queries readed from file.
bool recover(std::istream &str, char delim= '\n')
Reads from stream query.
#define for_(IT, BEG, END)
Convenient for-loops using iterator.
const char * c_str() const
String representation.
void writePoolQueriesToFile(const zypp::filesystem::Pathname &file, InputIterator begin, InputIterator end)
Writes all queries from begin to end.
std::string form(const char *format,...)
Printf style construction of std::string.
Base class for Exception.