1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
9 /** \file zypp/Package.h
12 #ifndef ZYPP_PACKAGE_H
13 #define ZYPP_PACKAGE_H
15 #include "zypp/ResObject.h"
16 #include "zypp/detail/PackageImplIf.h"
18 ///////////////////////////////////////////////////////////////////
20 { /////////////////////////////////////////////////////////////////
22 ///////////////////////////////////////////////////////////////////
24 // CLASS NAME : Package
26 /** Package interface.
28 class Package : public ResObject
31 typedef detail::PackageImplIf Impl;
33 typedef ResTraits<Self> TraitsType;
34 typedef TraitsType::PtrType Ptr;
35 typedef TraitsType::constPtrType constPtr;
38 /** Time of package installation */
39 Date installtime() const;
40 /** Get the package change log */
41 Changelog changelog() const;
43 Date buildtime() const;
45 std::string buildhost() const;
47 std::string distribution() const;
49 Vendor vendor() const;
51 Label license() const;
53 std::string packager() const;
55 PackageGroup group() const;
56 /** Don't ship it as class Url, because it might be
57 * in fact anything but a legal Url. */
58 std::string url() const;
60 std::string os() const;
70 ByteCount sourcesize() const;
72 ByteCount archivesize() const;
74 std::list<std::string> authors() const;
76 std::list<std::string> filenames() const;
78 License licenseToConfirm() const;
80 Pathname plainRpm() const;
82 std::list<PatchRpm> patchRpms() const;
84 std::list<DeltaRpm> deltaRpms() const;
88 Pathname getPlainRpm() const;
92 Pathname getDeltaRpm(BaseVersion & base_r) const;
96 Pathname getPatchRpm(BaseVersion & base_r) const;
98 bool installOnly() const;
104 Package( const NVRAD & nvrad_r );
109 /** Access implementation */
110 virtual Impl & pimpl() = 0;
111 /** Access implementation */
112 virtual const Impl & pimpl() const = 0;
114 ///////////////////////////////////////////////////////////////////
116 /////////////////////////////////////////////////////////////////
118 ///////////////////////////////////////////////////////////////////
119 #endif // ZYPP_PACKAGE_H