Package papyros :: Class Job
[hide private]
[frames] | no frames]

Class Job

source code

object --+
         |
        Job

Abstract base class of a callable to be called later.

It stores the result or raised exception of the last time it is called.

Instance Methods [hide private]
 
__init__(self, *args, **kwds)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
__hash__(self)
hash(x)
source code
 
__eq__(self, other) source code
 
__call__(self, *args, **kwds)
Abstract method; to be implemented by subclasses.
source code
 
_process(self)
Execute this job and store the result or raised exception.
source code

Inherited from object: __delattr__, __getattribute__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Class Variables [hide private]
  __counter = 0
Properties [hide private]
  result
Return the computed result for this processed job.

Inherited from object: __class__

Method Details [hide private]

__init__(self, *args, **kwds)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Decorators:
  • @synchronized
Overrides: object.__init__
(inherited documentation)

__hash__(self)
(Hashing function)

source code 
hash(x)
Overrides: object.__hash__
(inherited documentation)

_process(self)

source code 

Execute this job and store the result or raised exception.

To be called by Slave instances.

Property Details [hide private]

result

Return the computed result for this processed job.

If the callable had risen an exception, it is reraised here. The original traceback is also available as exc.__traceback__.

If this job has not been processed yet, it raises UnprocessedJobError.
Get Method:
unreachable.result(self) - Return the computed result for this processed job.