pub struct ProcessorMap { /* private fields */ }
Expand description

A type for storing the relationships between processor names and the processor itself

Processors must be registered with the ProcessorMap in the initialization phase of an application before workers are spawned in order to handle queued jobs.

Implementations§

Intialize a ProcessorMap

Register a Processor with this ProcessorMap.

ProcessorMaps are useless if no processors are registerd before workers are spawned, so make sure to register all your processors up-front.

Process a given job

This should not be called from outside implementations of a backgoround-jobs runtime. It is intended for internal use.

Trait Implementations§

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.