pub struct PullRequest {Show 20 fields
pub number: u64,
pub title: String,
pub description: String,
pub state: PullRequestState,
pub is_draft: bool,
pub author: Option<Principal>,
pub merger: Option<Principal>,
pub source_branch: String,
pub target_branch: String,
pub source_repo_id: Option<i64>,
pub target_repo_id: Option<i64>,
pub created: Option<i64>,
pub updated: Option<i64>,
pub merged: Option<i64>,
pub closed: Option<i64>,
pub web_url: Option<String>,
pub stats: Option<PullRequestStats>,
pub merge_check_status: Option<String>,
pub merge_conflicts: Vec<String>,
pub merge_method: Option<MergeMethod>,
}Expand description
A pull request.
Timestamps stay as the raw epoch integers GitFox sends. Interpreting them is a presentation concern, and keeping them raw means the JSON a machine reads never depends on this crate’s idea of a date format.
Fields§
§number: u64§title: String§description: String§state: PullRequestState§is_draft: bool§merger: Option<Principal>§source_branch: String§target_branch: String§source_repo_id: Option<i64>Differs from target_repo_id when the pull request comes from a fork.
target_repo_id: Option<i64>§created: Option<i64>§updated: Option<i64>§merged: Option<i64>§closed: Option<i64>§web_url: Option<String>§stats: Option<PullRequestStats>§merge_check_status: Option<String>§merge_conflicts: Vec<String>§merge_method: Option<MergeMethod>Implementations§
Source§impl PullRequest
impl PullRequest
Sourcepub fn display_state(&self) -> &'static str
pub fn display_state(&self) -> &'static str
open, draft, merged or closed — draft is a display state, not an
API one, but it is the first thing a reviewer wants to know.
Trait Implementations§
Source§impl Clone for PullRequest
impl Clone for PullRequest
Source§fn clone(&self) -> PullRequest
fn clone(&self) -> PullRequest
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 moreSource§impl Debug for PullRequest
impl Debug for PullRequest
Source§impl<'de> Deserialize<'de> for PullRequest
impl<'de> Deserialize<'de> for PullRequest
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
Auto Trait Implementations§
impl Freeze for PullRequest
impl RefUnwindSafe for PullRequest
impl Send for PullRequest
impl Sync for PullRequest
impl Unpin for PullRequest
impl UnsafeUnpin for PullRequest
impl UnwindSafe for PullRequest
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