Struct ReviewInput

Source
pub struct ReviewInput {
    pub message: Option<String>,
    pub labels: Option<HashMap<String, i8>>,
    pub comments: Option<HashMap<String, CommentInput>>,
    pub strict_labels: Option<bool>,
    pub drafts: Option<String>,
    pub notify: Option<String>,
    pub on_behalf_of: Option<String>,
    pub tag: Option<String>,
    pub omit_duplicate_comments: Option<bool>,
}
Expand description

The ReviewInput entity contains information for adding a review to a revision

Fields§

§message: Option<String>

The message to be added as review comment. V02.09

§labels: Option<HashMap<String, i8>>

The votes that should be added to the revision as a map that maps the label names to the voting values. V02.09

§comments: Option<HashMap<String, CommentInput>>

The comments that should be added as a map that maps a file path to a list of CommentInput entities. V02.09

§strict_labels: Option<bool>

Whether all labels are required to be within the user’s permitted ranges based on access controls. If true, attempting to use a label not granted to the user will fail the entire modify operation early. If false, the operation will execute anyway, but the proposed labels will be modified to be the “best” value allowed by the access controls. V02.09

§drafts: Option<String>

Draft handling that defines how draft comments are handled that are already in the database but that were not also described in this input. Allowed values are DELETE, PUBLISH and KEEP. If not set, the default is DELETE. V02.09

§notify: Option<String>

Notify handling that defines to whom email notifications should be sent after the review is stored. Allowed values are NONE, OWNER, OWNER_REVIEWERS and ALL. If not set, the default is ALL. V02.09

§on_behalf_of: Option<String>

{account-id} the review should be posted on behalf of. To use this option the caller must have been granted labelAs-NAME permission for all keys of labels. V02.09

§tag: Option<String>

Apply this tag to the review comment message, votes, and inline comments. Tags may be used by CI or other automated systems to distinguish them from human reviews. Comments with specific tag values can be filtered out in the web UI. V02.13

§omit_duplicate_comments: Option<bool>

If true, comments with the same content at the same place will be omitted V02.13

Trait Implementations§

Source§

impl Clone for ReviewInput

Source§

fn clone(&self) -> ReviewInput

Returns a copy of the value. Read more
1.0.0 · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for ReviewInput

Source§

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

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

impl<'de> Deserialize<'de> for ReviewInput

Source§

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 Serialize for ReviewInput

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. 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.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,