pub trait RustWorkloadFactory {
const FDB_API_VERSION: u32 = 740u32;
// Required method
fn create(name: String, context: WorkloadContext) -> WrappedWorkload;
}Expand description
Equivalent to the C++ abstract class FDBWorkloadFactory
Provided Associated Constants§
Sourceconst FDB_API_VERSION: u32 = 740u32
const FDB_API_VERSION: u32 = 740u32
The runtime FDB_API_VERSION to use
Required Methods§
Sourcefn create(name: String, context: WorkloadContext) -> WrappedWorkload
fn create(name: String, context: WorkloadContext) -> WrappedWorkload
If the test file contains a key-value pair workloadName the value will be passed to this method (empty string otherwise). This way, a library author can implement many workloads in one library and use the test file to chose which one to run (or run multiple workloads either concurrently or serially).
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.