pub struct ReviewSession {
pub name: String,
pub state: ReviewState,
pub created_at_ms: u64,
pub updated_at_ms: u64,
pub done_at_ms: Option<u64>,
pub comments: Vec<LineComment>,
pub next_comment_id: u64,
pub next_reply_id: u64,
}Fields§
§name: String§state: ReviewState§created_at_ms: u64§updated_at_ms: u64§done_at_ms: Option<u64>§comments: Vec<LineComment>§next_comment_id: u64§next_reply_id: u64Implementations§
Source§impl ReviewSession
impl ReviewSession
pub fn new(name: String, now_ms: u64) -> Self
pub fn set_state( &mut self, next: ReviewState, now_ms: u64, ) -> Result<(), String>
pub fn set_state_force( &mut self, next: ReviewState, now_ms: u64, ) -> Result<(), String>
pub fn add_comment(&mut self, new_comment: NewLineComment, now_ms: u64) -> u64
pub fn add_reply( &mut self, comment_id: u64, author: Author, body: String, now_ms: u64, ) -> Result<u64, String>
pub fn set_comment_status( &mut self, comment_id: u64, status: CommentStatus, actor: Author, now_ms: u64, ) -> Result<(), String>
pub fn set_comment_status_force( &mut self, comment_id: u64, status: CommentStatus, now_ms: u64, ) -> Result<(), String>
Trait Implementations§
Source§impl Clone for ReviewSession
impl Clone for ReviewSession
Source§fn clone(&self) -> ReviewSession
fn clone(&self) -> ReviewSession
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ReviewSession
impl Debug for ReviewSession
Source§impl<'de> Deserialize<'de> for ReviewSession
impl<'de> Deserialize<'de> for ReviewSession
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ReviewSession
impl PartialEq for ReviewSession
Source§impl Serialize for ReviewSession
impl Serialize for ReviewSession
impl Eq for ReviewSession
impl StructuralPartialEq for ReviewSession
Auto Trait Implementations§
impl Freeze for ReviewSession
impl RefUnwindSafe for ReviewSession
impl Send for ReviewSession
impl Sync for ReviewSession
impl Unpin for ReviewSession
impl UnsafeUnpin for ReviewSession
impl UnwindSafe for ReviewSession
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§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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more