Package daklib :: Module dbconn :: Class DBBinary
[hide private]
[frames] | no frames]

Class DBBinary

source code


Instance Methods [hide private]
 
__init__(self, package=None, source=None, version=None, maintainer=None, architecture=None, poolfile=None, binarytype='deb', fingerprint=None) source code
 
pkid(self) source code
 
name(self) source code
 
arch_string(self) source code
 
properties(self)
This method should be implemented by all derived classes and returns a list of the important properties.
source code
 
scan_contents(self)
Yields the contents of the package.
source code
text
read_control(self)
Reads the control information from a binary.
source code
dict
read_control_fields(self)
Reads the control information from a binary and return as a dictionary.
source code
 
proxy(self) source code

Inherited from ORMObject: __repr__, __str__, classname, clone, session

Class Methods [hide private]

Inherited from ORMObject: get

Class Variables [hide private]
  metadata = association_proxy('key', 'value')
Method Details [hide private]

pkid(self)

source code 
Decorators:
  • @property

name(self)

source code 
Decorators:
  • @property

arch_string(self)

source code 
Decorators:
  • @property

properties(self)

source code 

This method should be implemented by all derived classes and returns a list of the important properties. The properties 'created' and 'modified' will be added automatically. A suffix '_count' should be added to properties that are lists or query objects. The most important property name should be returned as the first element in the list because it is used by repr().

Overrides: ORMObject.properties
(inherited documentation)

scan_contents(self)

source code 

Yields the contents of the package. Only regular files are yielded and the path names are normalized after converting them from either utf-8 or iso8859-1 encoding. It yields the string ' <EMPTY PACKAGE>' if the package does not contain any regular file.

read_control(self)

source code 

Reads the control information from a binary.

Returns: text
stanza text of the control section.

read_control_fields(self)

source code 

Reads the control information from a binary and return as a dictionary.

Returns: dict
fields of the control section as a dictionary.

proxy(self)

source code 
Decorators:
  • @property