Struct gitlab::types::MergeRequest

source ·
pub struct MergeRequest {
Show 50 fields pub id: MergeRequestId, pub iid: MergeRequestInternalId, pub project_id: ProjectId, pub title: String, pub description: Option<String>, pub draft: bool, pub state: MergeRequestState, pub created_at: DateTime<Utc>, pub updated_at: DateTime<Utc>, pub merged_at: Option<DateTime<Utc>>, pub closed_at: Option<DateTime<Utc>>, pub merged_by: Option<UserBasic>, pub closed_by: Option<UserBasic>, pub target_branch: String, pub source_branch: String, pub upvotes: u64, pub downvotes: u64, pub author: UserBasic, pub assignee: Option<UserBasic>, pub assignees: Option<Vec<UserBasic>>, pub reviewers: Option<Vec<UserBasic>>, pub source_project_id: Option<ProjectId>, pub target_project_id: ProjectId, pub labels: Vec<String>, pub work_in_progress: bool, pub allow_collaboration: Option<bool>, pub allow_maintainer_to_push: Option<bool>, pub milestone: Option<Milestone>, pub squash: bool, pub merge_when_pipeline_succeeds: bool, pub merge_status: MergeStatus, pub sha: Option<ObjectId>, pub diff_refs: Option<DiffRefs>, pub merge_error: Option<String>, pub rebase_in_progress: Option<bool>, pub merge_commit_sha: Option<ObjectId>, pub squash_commit_sha: Option<ObjectId>, pub subscribed: Option<bool>, pub time_stats: IssuableTimeStats, pub blocking_discussions_resolved: bool, pub changes_count: Option<String>, pub user_notes_count: u64, pub discussion_locked: Option<bool>, pub should_remove_source_branch: Option<bool>, pub force_remove_source_branch: Option<bool>, pub has_conflicts: bool, pub user: Option<MergeRequestUser>, pub web_url: String, pub pipeline: Option<PipelineBasic>, pub first_contribution: Option<bool>,
}
👎Deprecated since 0.1609.0: define deserialization types in client code
Expand description

A merge request.

Fields§

§id: MergeRequestId
👎Deprecated since 0.1609.0: define deserialization types in client code

The ID of the merge request.

§iid: MergeRequestInternalId
👎Deprecated since 0.1609.0: define deserialization types in client code

The user-visible ID of the merge request.

§project_id: ProjectId
👎Deprecated since 0.1609.0: define deserialization types in client code

The ID of the project.

§title: String
👎Deprecated since 0.1609.0: define deserialization types in client code

The title of the merge request.

§description: Option<String>
👎Deprecated since 0.1609.0: define deserialization types in client code

The description of the merge request.

§draft: bool
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request is a draft or not.

§state: MergeRequestState
👎Deprecated since 0.1609.0: define deserialization types in client code

The state of the merge request.

§created_at: DateTime<Utc>
👎Deprecated since 0.1609.0: define deserialization types in client code

When the merge request was created.

§updated_at: DateTime<Utc>
👎Deprecated since 0.1609.0: define deserialization types in client code

When the merge request was last updated.

§merged_at: Option<DateTime<Utc>>
👎Deprecated since 0.1609.0: define deserialization types in client code

When the merge request was merged.

§closed_at: Option<DateTime<Utc>>
👎Deprecated since 0.1609.0: define deserialization types in client code

When the merge request was closed.

§merged_by: Option<UserBasic>
👎Deprecated since 0.1609.0: define deserialization types in client code

The user that merged the merge request.

§closed_by: Option<UserBasic>
👎Deprecated since 0.1609.0: define deserialization types in client code

The user that closed the merge request.

§target_branch: String
👎Deprecated since 0.1609.0: define deserialization types in client code

The target branch of the merge request.

§source_branch: String
👎Deprecated since 0.1609.0: define deserialization types in client code

The source branch of the merge request.

§upvotes: u64
👎Deprecated since 0.1609.0: define deserialization types in client code

The number of upvotes for the merge request.

§downvotes: u64
👎Deprecated since 0.1609.0: define deserialization types in client code

The number of downvotes against the merge request.

§author: UserBasic
👎Deprecated since 0.1609.0: define deserialization types in client code

The author of the merge request.

§assignee: Option<UserBasic>
👎Deprecated since 0.1609.0: define deserialization types in client code

The assignee of the merge request.

§assignees: Option<Vec<UserBasic>>
👎Deprecated since 0.1609.0: define deserialization types in client code

The assignees of the merge request.

§reviewers: Option<Vec<UserBasic>>
👎Deprecated since 0.1609.0: define deserialization types in client code

The reviewers of the merge request.

§source_project_id: Option<ProjectId>
👎Deprecated since 0.1609.0: define deserialization types in client code

The ID of the project hosting the source branch.

§target_project_id: ProjectId
👎Deprecated since 0.1609.0: define deserialization types in client code

The ID of the project hosting the target branch.

§labels: Vec<String>
👎Deprecated since 0.1609.0: define deserialization types in client code

The labels attached to the merge request.

§work_in_progress: bool
👎Deprecated since 0.1601.0: Use the ‘draft’ member instead.

Whether the merge request is a work-in-progress or not.

§allow_collaboration: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request allows a maintainer to collaborate.

§allow_maintainer_to_push: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request allows a maintainer to push (deprecated).

§milestone: Option<Milestone>
👎Deprecated since 0.1609.0: define deserialization types in client code

The milestone of the merge request.

§squash: bool
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether to squash commits on merge.

§merge_when_pipeline_succeeds: bool
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request will be merged once all pipelines succeed or not.

§merge_status: MergeStatus
👎Deprecated since 0.1609.0: define deserialization types in client code

The status of the merge request.

§sha: Option<ObjectId>
👎Deprecated since 0.1609.0: define deserialization types in client code

The object ID of the head of the source branch.

This is None if the source branch has been deleted.

§diff_refs: Option<DiffRefs>
👎Deprecated since 0.1609.0: define deserialization types in client code

The commits used to construct the merge request diffs.

§merge_error: Option<String>
👎Deprecated since 0.1609.0: define deserialization types in client code

Description of error if MR failed to merge.

§rebase_in_progress: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether a rebase is in progress.

§merge_commit_sha: Option<ObjectId>
👎Deprecated since 0.1609.0: define deserialization types in client code

The object ID of the commit which merged the merge request.

§squash_commit_sha: Option<ObjectId>
👎Deprecated since 0.1609.0: define deserialization types in client code

The object ID of the merge request squash commit.

§subscribed: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the current user is subscribed or not. GitLab does not include this in responses with lists of merge requests but does on an individual merge request.

§time_stats: IssuableTimeStats
👎Deprecated since 0.1609.0: define deserialization types in client code

Time estimates.

§blocking_discussions_resolved: bool
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether or not all blocking discussions are resolved.

§changes_count: Option<String>
👎Deprecated since 0.1609.0: define deserialization types in client code

The number of paths changed by the merge request.

This is an integer suffixed by + if there are more files changed than some threshold (probably determined by a timeout).

§user_notes_count: u64
👎Deprecated since 0.1609.0: define deserialization types in client code

The number of comments on the merge request.

§discussion_locked: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the discussion has been locked.

§should_remove_source_branch: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request should be deleted or not (set by the merger).

§force_remove_source_branch: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request should be deleted or not (set by the author).

§has_conflicts: bool
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the merge request currently has conflicts with the target branch.

§user: Option<MergeRequestUser>
👎Deprecated since 0.1609.0: define deserialization types in client code

Information about current user’s access to the merge request.

§web_url: String
👎Deprecated since 0.1609.0: define deserialization types in client code

The URL of the merge request.

§pipeline: Option<PipelineBasic>
👎Deprecated since 0.1609.0: define deserialization types in client code

Basic pipeline information for the MR.

§first_contribution: Option<bool>
👎Deprecated since 0.1609.0: define deserialization types in client code

Whether the user doesn’t have any commits in the repo, denoting the first contribution.

Trait Implementations§

source§

impl Clone for MergeRequest

source§

fn clone(&self) -> MergeRequest

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 MergeRequest

source§

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

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

impl<'de> Deserialize<'de> for MergeRequest

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 From<MergeRequestChanges> for MergeRequest

source§

fn from(mr: MergeRequestChanges) -> Self

Converts to this type from the input type.
source§

impl Serialize for MergeRequest

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> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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,

§

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>,

§

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>,

§

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> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

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