pub enum SessionRole {
Worker,
Orchestrator,
}Expand description
Role one session plays in a multi-session workflow.
The role is orthogonal to SessionStatus: an orchestrator moves through
the same lifecycle states as any other session, but its worktree exists only
for repository reads and never receives commits. Diff, merge, and
review-request affordances are therefore gated on the role rather than on a
dedicated lifecycle state.
Variants§
Worker
Ordinary session that owns the changes on its own branch.
Orchestrator
Controller session that plans and supervises child worker sessions.
Implementations§
Source§impl SessionRole
impl SessionRole
Sourcepub fn owns_branch_changes(self) -> bool
pub fn owns_branch_changes(self) -> bool
Returns whether this role produces commits on its own session branch.
Orchestrators read the repository to plan work but delegate every edit to child sessions, so their branch stays empty for the session’s whole lifetime.
Trait Implementations§
Source§impl Clone for SessionRole
impl Clone for SessionRole
Source§fn clone(&self) -> SessionRole
fn clone(&self) -> SessionRole
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 moreimpl Copy for SessionRole
Source§impl Debug for SessionRole
impl Debug for SessionRole
Source§impl Default for SessionRole
impl Default for SessionRole
Source§fn default() -> SessionRole
fn default() -> SessionRole
Returns the “default value” for a type. Read more
Source§impl Display for SessionRole
impl Display for SessionRole
impl Eq for SessionRole
Source§impl FromStr for SessionRole
impl FromStr for SessionRole
Source§impl PartialEq for SessionRole
impl PartialEq for SessionRole
impl StructuralPartialEq for SessionRole
Auto Trait Implementations§
impl Freeze for SessionRole
impl RefUnwindSafe for SessionRole
impl Send for SessionRole
impl Sync for SessionRole
impl Unpin for SessionRole
impl UnsafeUnpin for SessionRole
impl UnwindSafe for SessionRole
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoMaybeUndefined<T> for T
impl<T> IntoMaybeUndefined<T> for T
Source§fn into_maybe_undefined(self) -> MaybeUndefined<T>
fn into_maybe_undefined(self) -> MaybeUndefined<T>
Converts this value into a three-state builder argument.
Source§impl<T> IntoOption<T> for T
impl<T> IntoOption<T> for T
Source§fn into_option(self) -> Option<T>
fn into_option(self) -> Option<T>
Converts this value into an optional builder argument.