highfive/jobs.py
def get_job(self, callback):
        """
        Calls the given callback function when a job becomes available.
        """

        assert not self._closed

        if self._active_js is None or not self._active_js.job_available():
            self._ready_callbacks.append(callback)
        else:
            job = self._active_js.get_job()
            self._job_sources[job] = self._active_js
            callback(job)
def get_job(self, callback):
        assert not self._closed

        if self._active_js is None or not self._active_js.job_available():
            self._ready_callbacks.append(callback)
        else:
            job = self._active_js.get_job()
            self._job_sources[job] = self._active_js
            callback(job)
def get_job ( self , callback ) : assert not self . _closed if self . _active_js is None or not self . _active_js . job_available ( ) : self . _ready_callbacks . append ( callback ) else : job = self . _active_js . get_job ( ) self . _job_sources [ job ] = self . _active_js callback ( job )
Calls the given callback function when a job becomes available.
Calls the given callback function when a job becomes available .