Logo Search packages:      
Sourcecode: rapid-spring version File versions  Download package

def rapid::rapid::Repository::read_versions_gz (   self )
Reads versions.gz-formatted file into a dictionary of Packages.

Definition at line 342 of file rapid.py.

            """ Reads versions.gz-formatted file into a dictionary of Packages."""
            packages = {}

            def read_line(line):
                  row = line[:-1].split(',')   # tag,hex,dependencies,name
                  tag, hex, deps, name = row[0], row[1], psv(row[2]), row[3]
                  if not name in packages:
                        packages[name] = Package(hex, name, deps, repository = self)
                  assert packages[name].name == name
                  # Ignore package if the name was already present, but with
                  # different hex or different dependencies. (#9)
                  if (packages[name].hex == hex and
                        packages[name].dependencies == deps and tag):

            with closing(gzip.open(self.versions_gz)) as f:
                  map(read_line, f)

            return packages

Generated by  Doxygen 1.6.0   Back to index