Skip to main content

PaneSet

Struct PaneSet 

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

Owned group of pane handles.

Implementations§

Source§

impl PaneSet

Source

pub fn keyboard(&self) -> PaneSetKeyboard

Returns high-level keyboard actions broadcast to this pane set.

Source§

impl PaneSet

Source

pub fn new<I>(panes: I) -> Self
where I: IntoIterator<Item = Pane>,

Creates a pane set from pane handles.

Preserves caller order exactly. It does not deduplicate repeated pane handles and may contain panes from different daemon endpoints.

Source

pub fn panes(&self) -> &[Pane]

Returns the panes in their caller-provided order.

Source

pub fn len(&self) -> usize

Returns the number of panes in the set.

Source

pub fn is_empty(&self) -> bool

Returns true when the set contains no panes.

Source

pub async fn broadcast(&self, input: Input<'_>) -> Result<BroadcastResult>

Broadcasts text or one key token to every pane.

This delegates to the client-side broadcast implementation and returns the same partial-broadcast error when at least one pane rejects the input.

Source

pub async fn snapshot_all(&self) -> PaneSetBatch<PaneSnapshot>

Captures one fresh snapshot per pane.

The returned batch always contains per-pane successes and failures. Call PaneSetBatch::is_success when the caller requires every pane to succeed.

Source

pub async fn close_all(self) -> PaneSetBatch<PaneCloseOutcome>

Closes every pane by consuming this pane set.

Stale panes use the ordinary Pane::close idempotent semantics and return PaneCloseOutcome::AlreadyClosed as a success.

Source

pub fn expect_all(&self) -> PaneSetExpectation<'_>

Starts an all-panes visible-text expectation builder.

Source

pub fn expect_any(&self) -> PaneSetExpectation<'_>

Starts an any-pane visible-text expectation builder.

Source

pub fn wait_all(&self) -> PaneSetExpectation<'_>

Alias for Self::expect_all.

Source

pub fn wait_any(&self) -> PaneSetExpectation<'_>

Alias for Self::expect_any.

Trait Implementations§

Source§

impl Clone for PaneSet

Source§

fn clone(&self) -> PaneSet

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 PaneSet

Source§

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

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

impl Default for PaneSet

Source§

fn default() -> PaneSet

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

impl From<Vec<Pane>> for PaneSet

Source§

fn from(panes: Vec<Pane>) -> Self

Converts to this type from the input type.
Source§

impl FromIterator<Pane> for PaneSet

Source§

fn from_iter<T: IntoIterator<Item = Pane>>(iter: T) -> Self

Creates a value from an iterator. Read more
Source§

impl IntoIterator for PaneSet

Source§

type Item = Pane

The type of the elements being iterated over.
Source§

type IntoIter = IntoIter<Pane>

Which kind of iterator are we turning this into?
Source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. 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 = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.