diff options
Diffstat (limited to 'swig/ByteCount.i')
-rw-r--r-- | swig/ByteCount.i | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/swig/ByteCount.i b/swig/ByteCount.i new file mode 100644 index 0000000..03f17c6 --- /dev/null +++ b/swig/ByteCount.i @@ -0,0 +1,49 @@ + + +#ifdef SWIGRUBY + +namespace zypp +{ + // how to do that? + // %rename "ByteCount::operator SizeType()" to_i; +} + +#endif + + +// TODO: tell make about dependencies +%include <zypp/ByteCount.h> + + +#ifdef SWIGRUBY + +namespace zypp +{ + %extend ByteCount + { + long long int to_i() + { + ByteCount::SizeType tmp = *self; + return tmp; + } + } +} + +#endif + +#ifdef SWIGPYTHON + +namespace zypp +{ + %extend ByteCount + { + long long int __int__() + { + ByteCount::SizeType tmp = *self; + return tmp; + } + } +} + +#endif + |