pub trait TaskPoolImpl:
GstObjectImpl
+ Send
+ Sync {
type Handle: TaskHandle;
// Required method
fn push(
&self,
func: TaskPoolFunction,
) -> Result<Option<Self::Handle>, Error>;
// Provided methods
fn prepare(&self) -> Result<(), Error> { ... }
fn cleanup(&self) { ... }
}
Required Associated Types§
Sourcetype Handle: TaskHandle
type Handle: TaskHandle
Handle to be returned from the push
function to allow the caller to wait for the task’s
completion.
If unneeded, you can specify ()
or Infallible
for a handle
that does nothing on join
or drop.
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.