Struct Event

Source
pub struct Event {
Show 32 fields pub branch_protection_rule: Option<BranchProtectionRule>, pub check_run: Option<CheckRun>, pub check_suite: Option<CheckSuite>, pub create: Option<Create>, pub delete: Option<Delete>, pub deployment: Option<Deployment>, pub deployment_status: Option<DeploymentStatus>, pub discussion: Option<Discussion>, pub discussion_comment: Option<DiscussionComment>, pub fork: Option<bool>, pub gollum: Option<bool>, pub issue_comment: Option<IssueComment>, pub issues: Option<Issues>, pub label: Option<Label>, pub merge_group: Option<MergeGroup>, pub milestone: Option<Milestone>, pub page_build: Option<bool>, pub public: Option<bool>, pub pull_request: Option<PullRequest>, pub pull_request_review: Option<PullRequestReview>, pub pull_request_review_comment: Option<PullRequestReviewComment>, pub pull_request_target: Option<PullRequestTarget>, pub push: Option<Push>, pub registry_package: Option<RegistryPackage>, pub release: Option<Release>, pub repository_dispatch: Option<RepositoryDispatch>, pub schedule: Option<Schedule>, pub status: Option<bool>, pub watch: Option<Watch>, pub workflow_call: Option<WorkflowCall>, pub workflow_dispatch: Option<WorkflowDispatch>, pub workflow_run: Option<WorkflowRun>,
}
Expand description

Represents all possible webhook events that can trigger a workflow See: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows

Fields§

§branch_protection_rule: Option<BranchProtectionRule>§check_run: Option<CheckRun>§check_suite: Option<CheckSuite>§create: Option<Create>§delete: Option<Delete>§deployment: Option<Deployment>§deployment_status: Option<DeploymentStatus>§discussion: Option<Discussion>§discussion_comment: Option<DiscussionComment>§fork: Option<bool>§gollum: Option<bool>§issue_comment: Option<IssueComment>§issues: Option<Issues>§label: Option<Label>§merge_group: Option<MergeGroup>§milestone: Option<Milestone>§page_build: Option<bool>§public: Option<bool>§pull_request: Option<PullRequest>§pull_request_review: Option<PullRequestReview>§pull_request_review_comment: Option<PullRequestReviewComment>§pull_request_target: Option<PullRequestTarget>§push: Option<Push>§registry_package: Option<RegistryPackage>§release: Option<Release>§repository_dispatch: Option<RepositoryDispatch>§schedule: Option<Schedule>§status: Option<bool>§watch: Option<Watch>§workflow_call: Option<WorkflowCall>§workflow_dispatch: Option<WorkflowDispatch>§workflow_run: Option<WorkflowRun>

Implementations§

Source§

impl Event

Source

pub fn branch_protection_rule( self, value: impl Into<BranchProtectionRule>, ) -> Self

Sets the branch_protection_rule field of this struct.

Source

pub fn check_run(self, value: impl Into<CheckRun>) -> Self

Sets the check_run field of this struct.

Source

pub fn check_suite(self, value: impl Into<CheckSuite>) -> Self

Sets the check_suite field of this struct.

Source

pub fn create(self, value: impl Into<Create>) -> Self

Sets the create field of this struct.

Source

pub fn delete(self, value: impl Into<Delete>) -> Self

Sets the delete field of this struct.

Source

pub fn deployment(self, value: impl Into<Deployment>) -> Self

Sets the deployment field of this struct.

Source

pub fn deployment_status(self, value: impl Into<DeploymentStatus>) -> Self

Sets the deployment_status field of this struct.

Source

pub fn discussion(self, value: impl Into<Discussion>) -> Self

Sets the discussion field of this struct.

Source

pub fn discussion_comment(self, value: impl Into<DiscussionComment>) -> Self

Sets the discussion_comment field of this struct.

Source

pub fn fork(self, value: impl Into<bool>) -> Self

Sets the fork field of this struct.

Source

pub fn gollum(self, value: impl Into<bool>) -> Self

Sets the gollum field of this struct.

Source

pub fn issue_comment(self, value: impl Into<IssueComment>) -> Self

Sets the issue_comment field of this struct.

Source

pub fn issues(self, value: impl Into<Issues>) -> Self

Sets the issues field of this struct.

Source

pub fn label(self, value: impl Into<Label>) -> Self

Sets the label field of this struct.

Source

pub fn merge_group(self, value: impl Into<MergeGroup>) -> Self

Sets the merge_group field of this struct.

Source

pub fn milestone(self, value: impl Into<Milestone>) -> Self

Sets the milestone field of this struct.

Source

pub fn page_build(self, value: impl Into<bool>) -> Self

Sets the page_build field of this struct.

Source

pub fn public(self, value: impl Into<bool>) -> Self

Sets the public field of this struct.

Source

pub fn pull_request(self, value: impl Into<PullRequest>) -> Self

Sets the pull_request field of this struct.

Source

pub fn pull_request_review(self, value: impl Into<PullRequestReview>) -> Self

Sets the pull_request_review field of this struct.

Source

pub fn pull_request_review_comment( self, value: impl Into<PullRequestReviewComment>, ) -> Self

Sets the pull_request_review_comment field of this struct.

Source

pub fn pull_request_target(self, value: impl Into<PullRequestTarget>) -> Self

Sets the pull_request_target field of this struct.

Source

pub fn push(self, value: impl Into<Push>) -> Self

Sets the push field of this struct.

Source

pub fn registry_package(self, value: impl Into<RegistryPackage>) -> Self

Sets the registry_package field of this struct.

Source

pub fn release(self, value: impl Into<Release>) -> Self

Sets the release field of this struct.

Source

pub fn repository_dispatch(self, value: impl Into<RepositoryDispatch>) -> Self

Sets the repository_dispatch field of this struct.

Source

pub fn schedule(self, value: impl Into<Schedule>) -> Self

Sets the schedule field of this struct.

Source

pub fn status(self, value: impl Into<bool>) -> Self

Sets the status field of this struct.

Source

pub fn watch(self, value: impl Into<Watch>) -> Self

Sets the watch field of this struct.

Source

pub fn workflow_call(self, value: impl Into<WorkflowCall>) -> Self

Sets the workflow_call field of this struct.

Source

pub fn workflow_dispatch(self, value: impl Into<WorkflowDispatch>) -> Self

Sets the workflow_dispatch field of this struct.

Source

pub fn workflow_run(self, value: impl Into<WorkflowRun>) -> Self

Sets the workflow_run field of this struct.

Trait Implementations§

Source§

impl Clone for Event

Source§

fn clone(&self) -> Event

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 Event

Source§

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

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

impl Default for Event

Source§

fn default() -> Event

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Event

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 Merge for Event

Source§

fn merge(&mut self, other: Self)

Merge another object into this object.
Source§

impl PartialEq for Event

Source§

fn eq(&self, other: &Event) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Event

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
Source§

impl Eq for Event

Source§

impl StructuralPartialEq for Event

Auto Trait Implementations§

§

impl Freeze for Event

§

impl RefUnwindSafe for Event

§

impl Send for Event

§

impl Sync for Event

§

impl Unpin for Event

§

impl UnwindSafe for Event

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, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
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>,