pub struct TaskSuite {
pub tasks: Vec<TaskDefinition>,
pub metadata: SuiteMetadata,
}Expand description
A suite of benchmark tasks loaded from a JSON file.
The suite contains multiple tasks that can be run sequentially during batch benchmarking.
Fields§
§tasks: Vec<TaskDefinition>List of task definitions.
metadata: SuiteMetadataOptional suite-level metadata.
Implementations§
Source§impl TaskSuite
impl TaskSuite
Sourcepub fn from_file(path: impl AsRef<Path>) -> Result<Self, TaskDefinitionError>
pub fn from_file(path: impl AsRef<Path>) -> Result<Self, TaskDefinitionError>
Loads a task suite from a JSON file.
Sourcepub fn validate(&self) -> Result<(), TaskDefinitionError>
pub fn validate(&self) -> Result<(), TaskDefinitionError>
Validates all tasks in the suite.
Sourcepub fn filter_by_complexity(&self, complexity: &str) -> Vec<&TaskDefinition>
pub fn filter_by_complexity(&self, complexity: &str) -> Vec<&TaskDefinition>
Returns tasks filtered by complexity level.
Sourcepub fn filter_by_tag(&self, tag: &str) -> Vec<&TaskDefinition>
pub fn filter_by_tag(&self, tag: &str) -> Vec<&TaskDefinition>
Returns tasks filtered by tag.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TaskSuite
impl<'de> Deserialize<'de> for TaskSuite
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for TaskSuite
impl RefUnwindSafe for TaskSuite
impl Send for TaskSuite
impl Sync for TaskSuite
impl Unpin for TaskSuite
impl UnsafeUnpin for TaskSuite
impl UnwindSafe for TaskSuite
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more