12 #ifndef ZYPP_MEDIAPRODUCTS_H_
13 #define ZYPP_MEDIAPRODUCTS_H_
38 MediaProductEntry(
const Pathname & dir_r =
"/",
const std::string & name_r = std::string() )
57 template <
class _OutputIterator>
60 std::ifstream pfile( file_r.asString().c_str() );
61 while ( pfile.good() ) {
65 ERR <<
"Error parsing " << file_r << std::endl;
87 template <
class _OutputIterator>
94 Pathname products_file = Pathname(
"media.1/products");
98 products_file = media_mgr.
localPath (
id, products_file);
103 MIL <<
"No products description found on the Url" << std::endl;
void productsInMedia(const Url &url_r, _OutputIterator result)
Available products in a url location.
static void scanProductsFile(const Pathname &file_r, _OutputIterator result)
FIXME: add a comment here...
#define ZYPP_THROW(EXCPT)
Drops a logline and throws the Exception.
Represents an available product in media.
std::string stripFirstWord(std::string &line, const bool ltrim_first)
std::set< MediaProductEntry > MediaProductSet
A set of available products in media.
std::string getline(std::istream &str, const Trim trim_r)
Return stream content up to (but not returning) the next newline.
#define ZYPP_CAUGHT(EXCPT)
Drops a logline telling the Exception was caught (in order to handle it).
Base class for Exception.
bool operator<(const MediaProductEntry &rhs) const