%PDF- %PDF-
Direktori : /proc/self/root/proc/self/root/proc/self/root/lib64/python3.6/site-packages/libdnf/ |
Current File : //proc/self/root/proc/self/root/proc/self/root/lib64/python3.6/site-packages/libdnf/utils.py |
# This file was automatically generated by SWIG (http://www.swig.org). # Version 3.0.12 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. from sys import version_info as _swig_python_version_info if _swig_python_version_info >= (2, 7, 0): def swig_import_helper(): import importlib pkg = __name__.rpartition('.')[0] mname = '.'.join((pkg, '_utils')).lstrip('.') try: return importlib.import_module(mname) except ImportError: return importlib.import_module('_utils') _utils = swig_import_helper() del swig_import_helper elif _swig_python_version_info >= (2, 6, 0): def swig_import_helper(): from os.path import dirname import imp fp = None try: fp, pathname, description = imp.find_module('_utils', [dirname(__file__)]) except ImportError: import _utils return _utils try: _mod = imp.load_module('_utils', fp, pathname, description) finally: if fp is not None: fp.close() return _mod _utils = swig_import_helper() del swig_import_helper else: import _utils del _swig_python_version_info try: _swig_property = property except NameError: pass # Python < 2.2 doesn't have 'property'. try: import builtins as __builtin__ except ImportError: import __builtin__ def _swig_setattr_nondynamic(self, class_type, name, value, static=1): if (name == "thisown"): return self.this.own(value) if (name == "this"): if type(value).__name__ == 'SwigPyObject': self.__dict__[name] = value return method = class_type.__swig_setmethods__.get(name, None) if method: return method(self, value) if (not static): if _newclass: object.__setattr__(self, name, value) else: self.__dict__[name] = value else: raise AttributeError("You cannot add attributes to %s" % self) def _swig_setattr(self, class_type, name, value): return _swig_setattr_nondynamic(self, class_type, name, value, 0) def _swig_getattr(self, class_type, name): if (name == "thisown"): return self.this.own() method = class_type.__swig_getmethods__.get(name, None) if method: return method(self) raise AttributeError("'%s' object has no attribute '%s'" % (class_type.__name__, name)) def _swig_repr(self): try: strthis = "proxy of " + self.this.__repr__() except __builtin__.Exception: strthis = "" return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) try: _object = object _newclass = 1 except __builtin__.Exception: class _object: pass _newclass = 0 try: import weakref weakref_proxy = weakref.proxy except __builtin__.Exception: weakref_proxy = lambda x: x SHARED_PTR_DISOWN = _utils.SHARED_PTR_DISOWN class SQLite3(_object): __swig_setmethods__ = {} __setattr__ = lambda self, name, value: _swig_setattr(self, SQLite3, name, value) __swig_getmethods__ = {} __getattr__ = lambda self, name: _swig_getattr(self, SQLite3, name) __repr__ = _swig_repr def __init__(self, dbPath): this = _utils.new_SQLite3(dbPath) try: self.this.append(this) except __builtin__.Exception: self.this = this def close(self): return _utils.SQLite3_close(self) __swig_destroy__ = _utils.delete_SQLite3 __del__ = lambda self: None SQLite3_swigregister = _utils.SQLite3_swigregister SQLite3_swigregister(SQLite3) class Logger(_object): __swig_setmethods__ = {} __setattr__ = lambda self, name, value: _swig_setattr(self, Logger, name, value) __swig_getmethods__ = {} __getattr__ = lambda self, name: _swig_getattr(self, Logger, name) __repr__ = _swig_repr Level_CRITICAL = _utils.Logger_Level_CRITICAL Level_ERROR = _utils.Logger_Level_ERROR Level_WARNING = _utils.Logger_Level_WARNING Level_NOTICE = _utils.Logger_Level_NOTICE Level_INFO = _utils.Logger_Level_INFO Level_DEBUG = _utils.Logger_Level_DEBUG Level_TRACE = _utils.Logger_Level_TRACE if _newclass: levelToCStr = staticmethod(_utils.Logger_levelToCStr) else: levelToCStr = _utils.Logger_levelToCStr LOG_SOURCE_LIBDNF = _utils.Logger_LOG_SOURCE_LIBDNF LOG_SOURCE_LIBREPO = _utils.Logger_LOG_SOURCE_LIBREPO def critical(self, *args): return _utils.Logger_critical(self, *args) def error(self, *args): return _utils.Logger_error(self, *args) def warning(self, *args): return _utils.Logger_warning(self, *args) def notice(self, *args): return _utils.Logger_notice(self, *args) def info(self, *args): return _utils.Logger_info(self, *args) def debug(self, *args): return _utils.Logger_debug(self, *args) def trace(self, *args): return _utils.Logger_trace(self, *args) def write(self, *args): return _utils.Logger_write(self, *args) __swig_destroy__ = _utils.delete_Logger __del__ = lambda self: None def __init__(self): if self.__class__ == Logger: _self = None else: _self = self this = _utils.new_Logger(_self, ) try: self.this.append(this) except __builtin__.Exception: self.this = this def __disown__(self): self.this.disown() _utils.disown_Logger(self) return weakref_proxy(self) Logger_swigregister = _utils.Logger_swigregister Logger_swigregister(Logger) def Logger_levelToCStr(level): return _utils.Logger_levelToCStr(level) Logger_levelToCStr = _utils.Logger_levelToCStr class NullLogger(Logger): __swig_setmethods__ = {} for _s in [Logger]: __swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {})) __setattr__ = lambda self, name, value: _swig_setattr(self, NullLogger, name, value) __swig_getmethods__ = {} for _s in [Logger]: __swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {})) __getattr__ = lambda self, name: _swig_getattr(self, NullLogger, name) __repr__ = _swig_repr def write(self, *args): return _utils.NullLogger_write(self, *args) def __init__(self): this = _utils.new_NullLogger() try: self.this.append(this) except __builtin__.Exception: self.this = this __swig_destroy__ = _utils.delete_NullLogger __del__ = lambda self: None NullLogger_swigregister = _utils.NullLogger_swigregister NullLogger_swigregister(NullLogger) class Log(_object): __swig_setmethods__ = {} __setattr__ = lambda self, name, value: _swig_setattr(self, Log, name, value) __swig_getmethods__ = {} __getattr__ = lambda self, name: _swig_getattr(self, Log, name) __repr__ = _swig_repr if _newclass: setLogger = staticmethod(_utils.Log_setLogger) else: setLogger = _utils.Log_setLogger if _newclass: getLogger = staticmethod(_utils.Log_getLogger) else: getLogger = _utils.Log_getLogger def __init__(self): this = _utils.new_Log() try: self.this.append(this) except __builtin__.Exception: self.this = this __swig_destroy__ = _utils.delete_Log __del__ = lambda self: None Log_swigregister = _utils.Log_swigregister Log_swigregister(Log) def Log_setLogger(logger): return _utils.Log_setLogger(logger) Log_setLogger = _utils.Log_setLogger def Log_getLogger(): return _utils.Log_getLogger() Log_getLogger = _utils.Log_getLogger def decompress(inPath, outPath, outMode, compressType=None): return _utils.decompress(inPath, outPath, outMode, compressType) decompress = _utils.decompress def checksum_check(type, inPath, checksum_valid): return _utils.checksum_check(type, inPath, checksum_valid) checksum_check = _utils.checksum_check def checksum_value(type, inPath): return _utils.checksum_value(type, inPath) checksum_value = _utils.checksum_value # This file is compatible with both classic and new-style classes.