pub struct StepName(/* private fields */);Expand description
A validated logical step-definition name.
Implementations§
Source§impl StepName
impl StepName
Sourcepub fn new(value: impl Into<String>) -> Result<Self, DomainError>
pub fn new(value: impl Into<String>) -> Result<Self, DomainError>
Validates and constructs the name.
§Errors
Returns DomainError when the value is empty, too long, has
surrounding whitespace, or contains a control character.
Sourcepub fn into_string(self) -> String
pub fn into_string(self) -> String
Returns the validated value.
Trait Implementations§
impl Eq for StepName
Source§impl Ord for StepName
impl Ord for StepName
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for StepName
impl PartialOrd for StepName
impl StructuralPartialEq for StepName
Auto Trait Implementations§
impl Freeze for StepName
impl RefUnwindSafe for StepName
impl Send for StepName
impl Sync for StepName
impl Unpin for StepName
impl UnsafeUnpin for StepName
impl UnwindSafe for StepName
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