minideblib.DpkgDatalist
index
minideblib/DpkgDatalist.py

DpkgDatalist.py
#
# This module implements DpkgDatalist, an abstract class for storing 
# a list of objects in a file. Children of this class have to implement
# the load and _store methods.
#
# Copyright 2001 Wichert Akkerman <wichert@linux.com>
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.

 
Modules
       
minideblib.SafeWriteFile
os
sys

 
Classes
       
UserDict.UserDict
DpkgDatalist(UserDict.UserDict, _DpkgDatalist)
exceptions.Exception(exceptions.BaseException)
DpkgDatalistException
_DpkgDatalist
DpkgDatalist(UserDict.UserDict, _DpkgDatalist)
DpkgOrderedDatalist(minideblib.OrderedDict.OrderedDict, _DpkgDatalist)
minideblib.OrderedDict.OrderedDict(UserDict.UserDict)
DpkgOrderedDatalist(minideblib.OrderedDict.OrderedDict, _DpkgDatalist)

 
class DpkgDatalist(UserDict.UserDict, _DpkgDatalist)
    
Method resolution order:
DpkgDatalist
UserDict.UserDict
_DpkgDatalist

Methods defined here:
__init__(self, fn='')

Methods inherited from UserDict.UserDict:
__cmp__(self, dict)
__contains__(self, key)
__delitem__(self, key)
__getitem__(self, key)
__len__(self)
__repr__(self)
__setitem__(self, key, item)
clear(self)
copy(self)
get(self, key, failobj=None)
has_key(self, key)
items(self)
iteritems(self)
iterkeys(self)
itervalues(self)
keys(self)
pop(self, key, *args)
popitem(self)
setdefault(self, key, failobj=None)
update(self, dict=None, **kwargs)
values(self)

Class methods inherited from UserDict.UserDict:
fromkeys(cls, iterable, value=None) from __builtin__.classobj

Methods inherited from _DpkgDatalist:
store(self, fn=None)
Store variable data in a file.

 
class DpkgDatalistException(exceptions.Exception)
    
Method resolution order:
DpkgDatalistException
exceptions.Exception
exceptions.BaseException
__builtin__.object

Methods defined here:
__init__(self, message='', reason=0, file=None, line=None)

Data descriptors defined here:
__weakref__
list of weak references to the object (if defined)

Data and other attributes defined here:
SYNTAXERROR = 1
UNKNOWN = 0

Data and other attributes inherited from exceptions.Exception:
__new__ = <built-in method __new__ of type object at 0x81419a0>
T.__new__(S, ...) -> a new object with type S, a subtype of T

Methods inherited from exceptions.BaseException:
__delattr__(...)
x.__delattr__('name') <==> del x.name
__getattribute__(...)
x.__getattribute__('name') <==> x.name
__getitem__(...)
x.__getitem__(y) <==> x[y]
__getslice__(...)
x.__getslice__(i, j) <==> x[i:j]
 
Use of negative indices is not supported.
__reduce__(...)
__repr__(...)
x.__repr__() <==> repr(x)
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value
__setstate__(...)
__str__(...)
x.__str__() <==> str(x)

Data descriptors inherited from exceptions.BaseException:
__dict__
args
message
exception message

 
class DpkgOrderedDatalist(minideblib.OrderedDict.OrderedDict, _DpkgDatalist)
    
Method resolution order:
DpkgOrderedDatalist
minideblib.OrderedDict.OrderedDict
UserDict.UserDict
_DpkgDatalist

Methods defined here:
__init__(self, fn='')

Methods inherited from minideblib.OrderedDict.OrderedDict:
__cmp__(self, dict)
__delitem__(self, key)
__setitem__(self, key, value)
clear(self)
copy(self)
items(self)
keys(self)
update(self, dict)
values(self)

Methods inherited from UserDict.UserDict:
__contains__(self, key)
__getitem__(self, key)
__len__(self)
__repr__(self)
get(self, key, failobj=None)
has_key(self, key)
iteritems(self)
iterkeys(self)
itervalues(self)
pop(self, key, *args)
popitem(self)
setdefault(self, key, failobj=None)

Class methods inherited from UserDict.UserDict:
fromkeys(cls, iterable, value=None) from __builtin__.classobj

Methods inherited from _DpkgDatalist:
store(self, fn=None)
Store variable data in a file.