Skip to main content

Request

Enum Request 

Source
pub enum Request {
Show 13 variants Open(PathBuf), CommentsTaken, Agent(AgentEvent), Test(TestRun), Pane(String), Reply { id: u32, author: String, text: String, found: Sender<bool>, }, Suggest { file: String, line: usize, kind: String, quote: String, text: String, author: String, made: Sender<u32>, }, Threads(Sender<String>), TakeThreads(Sender<String>), Waiting(Sender<String>), Alone { key: u64, reply: Sender<bool>, }, Plan { path: PathBuf, reply: Sender<Decision>, }, Team { asked: Asked, reply: Sender<String>, },
}
Expand description

Requests that need the app itself, drained on its next tick.

Variants§

§

Open(PathBuf)

§

CommentsTaken

The socket thread already emptied the shared list.

§

Agent(AgentEvent)

§

Test(TestRun)

§

Pane(String)

Input for a Cellix running as a pane, as the mod’s JSON.

§

Reply

An agent answering a comment.

Fields

§id: u32
§author: String
§text: String
§found: Sender<bool>

Whether that comment exists, so an answer can’t vanish with a success.

§

Suggest

An agent suggesting a comment the reviewer didn’t make. Answers with its number.

Fields

§file: String
§line: usize
§kind: String
§quote: String
§text: String
§author: String
§made: Sender<u32>
§

Threads(Sender<String>)

Wants the comments on the project, as JSON.

§

TakeThreads(Sender<String>)

Wants the comments no agent has seen, as JSON, and marks them seen.

§

Waiting(Sender<String>)

Wants everything no agent has had yet, as JSON comments, and takes nothing: the review’s comments on code and the comments on documents, which are threads.

§

Alone

Asks whether the prompt with this key (prompt_key) is one Cellix typed in to go on its own, as Ask Agent on one comment’s card does, so the prompt hook hands it nothing else. Answered once: a second prompt with the same words is an ordinary one.

Fields

§key: u64
§reply: Sender<bool>
§

Plan

A plan is waiting. The connection stays open until reply is answered or dropped.

Fields

§path: PathBuf
§

Team

An agent starting, messaging or waiting for another. The connection stays open until reply has the answer’s line, which may be a while for a wait.

Fields

§asked: Asked

Trait Implementations§

Source§

impl Debug for Request

Source§

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

Formats the value using the given formatter. 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> 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> Same for T

Source§

type Output = T

Should always be Self
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.