11#include <zypp/base/Logger.h>
12#include <zypp/base/Gettext.h>
13#include <zypp/base/String.h>
14#include <zypp-core/base/InputStream>
15#include <zypp-core/base/UserRequestException>
20#include <zypp/PathInfo.h>
23using std::stringstream;
43 std::list<Pathname> entries;
53 for_(it, entries.begin(), entries.end() )
56 service_info.
setAlias((*it).basename());
63 DBG <<
"Plugin Service: " << service_info << endl;
64 callback(service_info);
Base class for Exception.
void setType(const repo::ServiceType &type)
Set service type.
void setUrl(const Url &url)
Set the service url (raw value)
void setPathName(const std::string &path, EEncoding eflag=zypp::url::E_DECODED)
Set the path name.
void setScheme(const std::string &scheme)
Set the scheme name in the URL.
Wrapper class for stat/lstat.
const char * c_str() const
String representation.
static void loadServices(const Pathname &path, const PluginServices::ProcessService &callback)
friend std::ostream & operator<<(std::ostream &str, const PluginServices &obj)
PluginServices(const Pathname &path, const ProcessService &callback)
function< bool(const ServiceInfo &)> ProcessService
Callback definition.
void setAutorefresh(bool autorefresh)
enable or disable autorefresh
void setAlias(const std::string &alias)
set the repository alias
String related utilities and Regular expression matching.
int readdir(std::list< std::string > &retlist_r, const Pathname &path_r, bool dots_r)
Return content of directory via retlist.
std::string form(const char *format,...) __attribute__((format(printf
Printf style construction of std::string.
Easy-to use interface to the ZYPP dependency resolver.
static const ServiceType PLUGIN
Plugin services are scripts installed on your system that provide the package manager with repositori...
#define for_(IT, BEG, END)
Convenient for-loops using iterator.
#define ZYPP_THROW(EXCPT)
Drops a logline and throws the Exception.