#[non_exhaustive]pub struct RepositoryEventConfig {
pub repository: String,
pub repository_type: RepositoryType,
pub filter: Option<Filter>,
/* private fields */
}
Expand description
The configuration of a trigger that creates a build whenever an event from Repo API is received.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.repository: String
The resource name of the Repo API resource.
repository_type: RepositoryType
Output only. The type of the SCM vendor the repository points to.
filter: Option<Filter>
The types of filter to trigger a build.
Implementations§
Source§impl RepositoryEventConfig
impl RepositoryEventConfig
pub fn new() -> Self
Sourcepub fn set_repository<T: Into<String>>(self, v: T) -> Self
pub fn set_repository<T: Into<String>>(self, v: T) -> Self
Sets the value of repository.
Sourcepub fn set_repository_type<T: Into<RepositoryType>>(self, v: T) -> Self
pub fn set_repository_type<T: Into<RepositoryType>>(self, v: T) -> Self
Sets the value of repository_type.
Sourcepub fn set_filter<T: Into<Option<Filter>>>(self, v: T) -> Self
pub fn set_filter<T: Into<Option<Filter>>>(self, v: T) -> Self
Sets the value of filter.
Note that all the setters affecting filter
are mutually
exclusive.
Sourcepub fn pull_request(&self) -> Option<&Box<PullRequestFilter>>
pub fn pull_request(&self) -> Option<&Box<PullRequestFilter>>
The value of filter
if it holds a PullRequest
, None
if the field is not set or
holds a different branch.
Sourcepub fn set_pull_request<T: Into<Box<PullRequestFilter>>>(self, v: T) -> Self
pub fn set_pull_request<T: Into<Box<PullRequestFilter>>>(self, v: T) -> Self
Sets the value of filter
to hold a PullRequest
.
Note that all the setters affecting filter
are
mutually exclusive.
Trait Implementations§
Source§impl Clone for RepositoryEventConfig
impl Clone for RepositoryEventConfig
Source§fn clone(&self) -> RepositoryEventConfig
fn clone(&self) -> RepositoryEventConfig
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 RepositoryEventConfig
impl Debug for RepositoryEventConfig
Source§impl Default for RepositoryEventConfig
impl Default for RepositoryEventConfig
Source§fn default() -> RepositoryEventConfig
fn default() -> RepositoryEventConfig
Returns the “default value” for a type. Read more
Source§impl Message for RepositoryEventConfig
impl Message for RepositoryEventConfig
Source§impl PartialEq for RepositoryEventConfig
impl PartialEq for RepositoryEventConfig
impl StructuralPartialEq for RepositoryEventConfig
Auto Trait Implementations§
impl Freeze for RepositoryEventConfig
impl RefUnwindSafe for RepositoryEventConfig
impl Send for RepositoryEventConfig
impl Sync for RepositoryEventConfig
impl Unpin for RepositoryEventConfig
impl UnwindSafe for RepositoryEventConfig
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