pub struct TaskProfiles { /* private fields */ }Expand description
The profiles of every task kind: the shipped ones, and a deployment’s overrides.
Keyed by the kind’s name (segment, route, …), which is also how TOML names them.
Implementations§
Source§impl TaskProfiles
impl TaskProfiles
Sourcepub fn get(&self, kind: TaskKind) -> TaskProfile
pub fn get(&self, kind: TaskKind) -> TaskProfile
The profile kind runs under.
Sourcepub fn with(self, kind: TaskKind, profile: TaskProfile) -> Self
pub fn with(self, kind: TaskKind, profile: TaskProfile) -> Self
Replaces the profile of kind.
Sourcepub fn adjust(
self,
kind: TaskKind,
change: impl FnOnce(TaskProfile) -> TaskProfile,
) -> Self
pub fn adjust( self, kind: TaskKind, change: impl FnOnce(TaskProfile) -> TaskProfile, ) -> Self
Adjusts the profile of kind, starting from what it is now.
Sourcepub fn overridden(&self) -> impl Iterator<Item = &str>
pub fn overridden(&self) -> impl Iterator<Item = &str>
Every overridden kind name, so a configuration can be checked for typos.
Every pool tag the profiles name, so the pool can be checked for them.
Trait Implementations§
Source§impl Clone for TaskProfiles
impl Clone for TaskProfiles
Source§impl Debug for TaskProfiles
impl Debug for TaskProfiles
Source§impl Default for TaskProfiles
impl Default for TaskProfiles
Source§impl<'de> Deserialize<'de> for TaskProfiles
impl<'de> Deserialize<'de> for TaskProfiles
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
Source§impl PartialEq for TaskProfiles
impl PartialEq for TaskProfiles
Source§impl Serialize for TaskProfiles
impl Serialize for TaskProfiles
impl StructuralPartialEq for TaskProfiles
Auto Trait Implementations§
impl Freeze for TaskProfiles
impl RefUnwindSafe for TaskProfiles
impl Send for TaskProfiles
impl Sync for TaskProfiles
impl Unpin for TaskProfiles
impl UnsafeUnpin for TaskProfiles
impl UnwindSafe for TaskProfiles
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