667d146464424721ee913ea052155dab97ed661d
[platform/upstream/libzypp.git] / zypp2 / repo / memory / DSrcPackageImpl.h
1 /*---------------------------------------------------------------------\
2 |                          ____ _   __ __ ___                          |
3 |                         |__  / \ / / . \ . \                         |
4 |                           / / \ V /|  _/  _/                         |
5 |                          / /__ | | | | | |                           |
6 |                         /_____||_| |_| |_|                           |
7 |                                                                      |
8 \---------------------------------------------------------------------*/
9 /** \file       zypp2/repository/memory/SrcPackageImpl.h
10  *
11 */
12 #ifndef ZYPP_SOURCE_MEMORYSRCPackageIMPL_H
13 #define ZYPP_SOURCE_MEMORYSRCPackageIMPL_H
14
15 #include "zypp/detail/SrcPackageImplIf.h"
16 #include "zypp/Source.h"
17 #include "zypp/DiskUsage.h"
18 #include "zypp/data/ResolvableData.h"
19
20 ///////////////////////////////////////////////////////////////////
21 namespace zypp
22 { /////////////////////////////////////////////////////////////////
23   ///////////////////////////////////////////////////////////////////
24   namespace repo
25   { /////////////////////////////////////////////////////////////////
26     namespace memory
27     { /////////////////////////////////////////////////////////////////
28
29       ///////////////////////////////////////////////////////////////////
30       //
31       //        CLASS NAME : SrcPackageImpl
32       //
33       /**
34       */
35       struct SrcPackageImpl : public zypp::detail::SrcPackageImplIf
36       {
37         SrcPackageImpl(data::SrcPackage_Ptr ptr);
38         virtual ~SrcPackageImpl();
39
40         /** */
41         virtual Pathname location() const;
42         /** */
43         virtual ByteCount archivesize() const;
44         /** */
45         virtual DiskUsage diskusage() const;
46         /** */
47         virtual unsigned sourceMediaNr() const;
48
49 private:
50         ByteCount _archivesize;
51         unsigned _media_number;
52         Pathname _location;
53         DiskUsage _diskusage;
54 public:
55         Source_Ref source() const;
56       };
57       ///////////////////////////////////////////////////////////////////
58       /////////////////////////////////////////////////////////////////
59     } // namespace memory
60     /////////////////////////////////////////////////////////////////
61   } // namespace repository
62   ///////////////////////////////////////////////////////////////////
63   /////////////////////////////////////////////////////////////////
64 } // namespace zypp
65 ///////////////////////////////////////////////////////////////////
66 #endif // ZYPP_SOURCE_MEMORY_SRCPACKAGEIMPL_H