Skip to main content

WorkflowList

Struct WorkflowList 

Source
pub struct WorkflowList { /* private fields */ }
Expand description

The workflow table as it accumulates pages.

Infinite scroll appends pages; a refresh or a new query replaces them. Two properties have to hold no matter which happened:

  • Sorted newest-first. The server does not order ListWorkflowExecutions, and the dev server’s standard visibility store rejects ORDER BY outright, so the ordering is this type’s job rather than the query’s.
  • No duplicates. Pages are snapshots of a set that is changing underneath them, so the same execution can legitimately arrive on two pages. A table that shows a workflow twice makes the operator doubt the whole screen.

Implementations§

Source§

impl WorkflowList

Source

pub fn rows(&self) -> &[WorkflowRow]

Source

pub fn len(&self) -> usize

Source

pub fn is_empty(&self) -> bool

Source

pub fn tokens(&self) -> &[(String, Vec<u8>)]

Per-namespace continuation tokens to send with the next page request.

Source

pub fn has_more(&self) -> bool

Whether any namespace still has pages left.

Source

pub fn reset(&mut self, rows: Vec<WorkflowRow>, tokens: Vec<(String, Vec<u8>)>)

Start over: a new query, or a refresh of the current one.

Source

pub fn append(&mut self, rows: Vec<WorkflowRow>, tokens: Vec<(String, Vec<u8>)>)

Add the next page.

Source

pub fn position_of(&self, key: (&str, &str)) -> Option<usize>

Where the row with this key sits now, if it is still listed.

Trait Implementations§

Source§

impl Clone for WorkflowList

Source§

fn clone(&self) -> WorkflowList

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for WorkflowList

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for WorkflowList

Source§

fn default() -> WorkflowList

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.