pub struct FoldedStack {
pub frames: Vec<String>,
pub value: u64,
}Expand description
One folded-stack line: a base→leaf frame path and its integer weight.
Fields§
§frames: Vec<String>Frames from base (root) to leaf, e.g.
[“-home-dev-acme-app”, “
value: u64Weight in the chosen metric’s unit (tokens, or micro-USD for cost).
Implementations§
Source§impl FoldedStack
impl FoldedStack
Sourcepub fn to_folded_line(&self) -> String
pub fn to_folded_line(&self) -> String
Render as an inferno folded line: frame;frame;… value.
(Frame labels are sanitized so ;/whitespace can’t corrupt the format.)
Trait Implementations§
Source§impl Clone for FoldedStack
impl Clone for FoldedStack
Source§fn clone(&self) -> FoldedStack
fn clone(&self) -> FoldedStack
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 FoldedStack
impl Debug for FoldedStack
impl Eq for FoldedStack
Source§impl PartialEq for FoldedStack
impl PartialEq for FoldedStack
Source§fn eq(&self, other: &FoldedStack) -> bool
fn eq(&self, other: &FoldedStack) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for FoldedStack
impl Serialize for FoldedStack
impl StructuralPartialEq for FoldedStack
Auto Trait Implementations§
impl Freeze for FoldedStack
impl RefUnwindSafe for FoldedStack
impl Send for FoldedStack
impl Sync for FoldedStack
impl Unpin for FoldedStack
impl UnsafeUnpin for FoldedStack
impl UnwindSafe for FoldedStack
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