#[non_exhaustive]pub struct PullRequest {
pub name: String,
pub title: String,
pub body: String,
pub base: Option<Branch>,
pub head: Option<Branch>,
pub state: State,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub close_time: Option<Timestamp>,
/* private fields */
}Expand description
Metadata of a PullRequest. PullRequest is the request from a user to merge a branch (head) into another branch (base).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringOutput only. A unique identifier for a PullRequest. The number appended at
the end is generated by the server. Format:
projects/{project}/locations/{location}/repositories/{repository}/pullRequests/{pull_request_id}
title: StringRequired. The pull request title.
body: StringOptional. The pull request body. Provides a detailed description of the changes.
base: Option<Branch>Required. The branch to merge changes in.
head: Option<Branch>Immutable. The branch containing the changes to be merged.
state: StateOutput only. State of the pull request (open, closed or merged).
create_time: Option<Timestamp>Output only. Creation timestamp.
update_time: Option<Timestamp>Output only. Last updated timestamp.
close_time: Option<Timestamp>Output only. Close timestamp (if closed or merged). Cleared when pull request is re-opened.
Implementations§
Source§impl PullRequest
impl PullRequest
pub fn new() -> Self
Sourcepub fn set_or_clear_base<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_base<T>(self, v: Option<T>) -> Self
Sets or clears the value of base.
Sourcepub fn set_or_clear_head<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_head<T>(self, v: Option<T>) -> Self
Sets or clears the value of head.
Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
Sourcepub fn set_close_time<T>(self, v: T) -> Self
pub fn set_close_time<T>(self, v: T) -> Self
Sets the value of close_time.
Sourcepub fn set_or_clear_close_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_close_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of close_time.
Trait Implementations§
Source§impl Clone for PullRequest
impl Clone for PullRequest
Source§fn clone(&self) -> PullRequest
fn clone(&self) -> PullRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more