pub struct VisualLabel {
pub dimension: String,
pub scope_id: String,
pub value: String,
pub in_range: usize,
pub entries: usize,
pub last_observed_at: Option<String>,
}Expand description
One label the about holds, as a renderer draws it: the key (dimension)
and the value, both as the coordinates spell them and as the catalogue
speaks, with how many entries stand in it across all time (entries) and
how many inside the projected range on the selected clock (in_range).
A label with nothing in range is still here. A lane that exists only
while the window holds one of its entries cannot show a reader that a
label is empty here; it can only fail to show the label at all. The
catalogue is read off the same contains_entry edges kmp_wake reads,
before the read’s own dimension filter narrows them, so the rows a
renderer draws are the about’s labels, not the window’s.
Fields§
§dimension: String§scope_id: String§value: String§in_range: usize§entries: usize§last_observed_at: Option<String>Implementations§
Source§impl VisualLabel
impl VisualLabel
Sourcepub fn catalogue(bundle: &KmpBundle) -> Vec<Self>
pub fn catalogue(bundle: &KmpBundle) -> Vec<Self>
Every label the bundle’s contains_entry edges name, most used
first, then by key and value, so the order is the same on every run.
in_range is zero until the projection counts its own entries.
Sourcepub fn counted<'a>(
labels: Vec<Self>,
in_range: impl IntoIterator<Item = &'a (String, String)>,
) -> Vec<Self>
pub fn counted<'a>( labels: Vec<Self>, in_range: impl IntoIterator<Item = &'a (String, String)>, ) -> Vec<Self>
The same catalogue with the projected range counted in: every label a
positioned entry stands in gains its in_range, and a label the
entries name that the catalogue somehow lacks is added rather than
dropped, so a row is never drawn for a label the list does not hold.
Trait Implementations§
Source§impl Clone for VisualLabel
impl Clone for VisualLabel
Source§fn clone(&self) -> VisualLabel
fn clone(&self) -> VisualLabel
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more