src packages do provide archivesize and diskusage
authorKlaus Kaempf <kkaempf@suse.de>
Wed, 22 Feb 2006 22:01:03 +0000 (22:01 +0000)
committerKlaus Kaempf <kkaempf@suse.de>
Wed, 22 Feb 2006 22:01:03 +0000 (22:01 +0000)
zypp/SrcPackage.cc
zypp/SrcPackage.h
zypp/detail/SrcPackageImplIf.cc
zypp/detail/SrcPackageImplIf.h

index b23de61..acd945d 100644 (file)
@@ -44,6 +44,12 @@ namespace zypp
   //
   ///////////////////////////////////////////////////////////////////
 
+  ByteCount SrcPackage::archivesize() const
+  { return pimpl().archivesize(); }
+
+  DiskUsage SrcPackage::diskusage() const
+  { return pimpl().diskusage(); }
+
   unsigned SrcPackage::mediaId() const
   { return pimpl().mediaId(); }
 
index e4691b4..b7f3575 100644 (file)
@@ -38,6 +38,10 @@ namespace zypp
     typedef TraitsType::constPtrType constPtr;
 
   public:
+    /** */
+    ByteCount archivesize() const;
+    /** Disk usage per directory */
+    DiskUsage diskusage() const;
     /** ID of the media */
     unsigned mediaId() const;
     /** location in source */
index 039618c..25f4719 100644 (file)
@@ -26,6 +26,12 @@ namespace zypp
     // as far as resonable.
     /////////////////////////////////////////////////////////////////
 
+      ByteCount SrcPackageImplIf::archivesize() const
+      { return ByteCount(); }
+
+      DiskUsage SrcPackageImplIf::diskusage() const
+      { return DiskUsage(); }      
+
       Pathname SrcPackageImplIf::location() const
       { return Pathname(); }
 
index ae55029..da9c43f 100644 (file)
@@ -16,6 +16,7 @@
 
 #include "zypp/detail/ResObjectImplIf.h"
 #include "zypp/Pathname.h"
+#include "zypp/DiskUsage.h"
 
 ///////////////////////////////////////////////////////////////////
 namespace zypp
@@ -40,6 +41,10 @@ namespace zypp
 
     public:
       /** */
+      virtual ByteCount archivesize() const PURE_VIRTUAL;
+      /** */
+      virtual DiskUsage diskusage() const PURE_VIRTUAL;
+      /** */
       virtual Pathname location() const PURE_VIRTUAL;
       /** */
       virtual unsigned mediaId() const PURE_VIRTUAL;