':return: A ``bytes`` representation of the desired version comparison
which can be parsed by the package management tools associated with
``package_type``.
:raises: ``ValueError`` if supplied with an unrecognised
``package_type``.'

def format(self, package_type):

    if (package_type == PackageTypes.DEB):
        if self.version:
            return ('%s    (%s    %s)' % (self.package, self.compare, self.version))
        else:
            return self.package
    elif (package_type == PackageTypes.RPM):
        if self.version:
            return ('%s    %s    %s' % (self.package, self.compare, self.version))
        else:
            return self.package
    else:
        raise ValueError('Unknown    package    type.')
