pub enum MessageStyle {
SolidArrow,
DashedArrow,
SolidLine,
DashedLine,
}Expand description
The visual style of a sequence-diagram message arrow.
Variants§
SolidArrow
Solid line with an arrowhead: ->>.
DashedArrow
Dashed line with an arrowhead: -->>.
SolidLine
Solid line without arrowhead: ->.
DashedLine
Dashed line without arrowhead: -->.
Implementations§
Source§impl MessageStyle
impl MessageStyle
Sourcepub fn is_dashed(self) -> bool
pub fn is_dashed(self) -> bool
Returns true when the line should be rendered with a dashed glyph.
§Examples
use mermaid_text::sequence::MessageStyle;
assert!(MessageStyle::DashedArrow.is_dashed());
assert!(MessageStyle::DashedLine.is_dashed());
assert!(!MessageStyle::SolidArrow.is_dashed());
assert!(!MessageStyle::SolidLine.is_dashed());Sourcepub fn has_arrow(self) -> bool
pub fn has_arrow(self) -> bool
Returns true when an arrowhead should be drawn at the target end.
§Examples
use mermaid_text::sequence::MessageStyle;
assert!(MessageStyle::SolidArrow.has_arrow());
assert!(MessageStyle::DashedArrow.has_arrow());
assert!(!MessageStyle::SolidLine.has_arrow());
assert!(!MessageStyle::DashedLine.has_arrow());Trait Implementations§
Source§impl Clone for MessageStyle
impl Clone for MessageStyle
Source§fn clone(&self) -> MessageStyle
fn clone(&self) -> MessageStyle
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MessageStyle
impl Debug for MessageStyle
Source§impl PartialEq for MessageStyle
impl PartialEq for MessageStyle
Source§fn eq(&self, other: &MessageStyle) -> bool
fn eq(&self, other: &MessageStyle) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for MessageStyle
impl Eq for MessageStyle
impl StructuralPartialEq for MessageStyle
Auto Trait Implementations§
impl Freeze for MessageStyle
impl RefUnwindSafe for MessageStyle
impl Send for MessageStyle
impl Sync for MessageStyle
impl Unpin for MessageStyle
impl UnsafeUnpin for MessageStyle
impl UnwindSafe for MessageStyle
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