'Convert a legacy URL to a job destination'

def url_to_destination(self, url):

    if (not url):
        return
    native_spec = url.split('/')[2]
    if native_spec:
        params = dict(nativeSpecification=native_spec)
        log.debug(("Converted    URL    '%s'    to    destination    runner=drmaa,    params=%s" % (url, params)))
        return JobDestination(runner='drmaa', params=params)
    else:
        log.debug(("Converted    URL    '%s'    to    destination    runner=drmaa" % url))
        return JobDestination(runner='drmaa')
