libzypp: zypp/parser/RepoindexFileReader.h Source File

libzypp 17.38.8

RepoindexFileReader.h
Go to the documentation of this file.
1/*---------------------------------------------------------------------\
2| ____ _ __ __ ___ |
3| |__ / \ / / . \ . \ |
4| / / \ V /| _/ _/ |
5| / /__ | | | | | | |
6| /_____||_| |_| |_| |
7| |
8\---------------------------------------------------------------------*/
12#ifndef zypp_source_yum_RepoindexFileReader_H
13#define zypp_source_yum_RepoindexFileReader_H
14
15#include <zypp-core/base/PtrTypes.h>
16#include <zypp-core/base/NonCopyable.h>
17#include <zypp-core/base/Function.h>
18#include <zypp-core/base/InputStream>
19#include <zypp-core/Pathname.h>
20#include <zypp-core/Date.h>
21
22namespace zypp
23{
24 class RepoInfo;
25
26 namespace parser
27 {
28
44 class ZYPP_API RepoindexFileReader : private base::NonCopyable
45 {
46 public:
52 using ProcessResource = function<bool (const RepoInfo &)>;
53
62 RepoindexFileReader(Pathname repoindexFile,
63 ProcessResource callback);
64
73 RepoindexFileReader( const InputStream &is,
74 ProcessResource callback );
75
79 ~RepoindexFileReader();
80
82 Date::Duration ttl() const;
83
84 private:
85 class Impl;
86 RW_pointer<Impl,rw_pointer::Scoped<Impl> > _pimpl;
87 };
88
89
90 } // ns parser
91} // ns zypp
92
93#endif /*zypp_source_yum_RepoindexFileReader_H*/
94
95// vim: set ts=2 sts=2 sw=2 et ai:
Date.h
Function.h
NonCopyable.h
Pathname.h
PtrTypes.h
bool
zypp::Date::Duration
time_t Duration
Definition Date.h:39
zypp::InputStream
Helper to create and pass std::istream.
Definition inputstream.h:57
zypp::RepoInfo
What is known about a repository.
Definition RepoInfo.h:72
zypp::filesystem::Pathname
Pathname.
Definition Pathname.h:48
zypp::parser::RepoindexFileReader::Impl
Definition RepoindexFileReader.cc:126
zypp::parser::RepoindexFileReader::ProcessResource
function< bool(const RepoInfo &)> ProcessResource
Callback definition.
Definition RepoindexFileReader.h:52
zypp::parser::RepoindexFileReader::_pimpl
RW_pointer< Impl, rw_pointer::Scoped< Impl > > _pimpl
Definition RepoindexFileReader.h:86
zypp::parser::RepoindexFileReader::RepoindexFileReader
RepoindexFileReader(Pathname repoindexFile, ProcessResource callback)
CTOR.
Definition RepoindexFileReader.cc:332
zypp::parser::RepoindexFileReader::ttl
Date::Duration ttl() const
Metadata TTL (repoindex.xml:xpath:/repoindex@ttl or 0).
Definition RepoindexFileReader.cc:343
zypp::base::NonCopyable
boost::noncopyable NonCopyable
Ensure derived classes cannot be copied.
Definition NonCopyable.h:26
zypp::callback
Callbacks light.
Definition Callback.h:146
zypp::parser
Definition HistoryLogReader.cc:30
zypp
Easy-to use interface to the ZYPP dependency resolver.
Definition CodePitfalls.doc:2
zypp::ZYPP_API
const Arch Arch_empty ZYPP_API
relates: Arch This is an empty Arch represented by an empty string.
Definition Arch.h:173
zypp::RW_pointer
Wrapper for const correct access via Smart pointer types.
Definition PtrTypes.h:293