Struct octocrab::models::webhook_events::WebhookEvent
source · #[non_exhaustive]pub struct WebhookEvent {
pub sender: Option<Author>,
pub repository: Option<Repository>,
pub organization: Option<Organization>,
pub installation: Option<EventInstallation>,
pub kind: WebhookEventType,
pub specific: WebhookEventPayload,
}
Expand description
A GitHub webhook event.
The structure is separated in common fields and specific fields, so you can always access the common values without needing to match the exact variant.
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.sender: Option<Author>
§repository: Option<Repository>
§organization: Option<Organization>
§installation: Option<EventInstallation>
§kind: WebhookEventType
§specific: WebhookEventPayload
Implementations§
Trait Implementations§
source§impl Clone for WebhookEvent
impl Clone for WebhookEvent
source§fn clone(&self) -> WebhookEvent
fn clone(&self) -> WebhookEvent
Returns a copy 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 WebhookEvent
impl Debug for WebhookEvent
source§impl PartialEq for WebhookEvent
impl PartialEq for WebhookEvent
source§fn eq(&self, other: &WebhookEvent) -> bool
fn eq(&self, other: &WebhookEvent) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for WebhookEvent
impl Serialize for WebhookEvent
impl StructuralPartialEq for WebhookEvent
Auto Trait Implementations§
impl Freeze for WebhookEvent
impl RefUnwindSafe for WebhookEvent
impl Send for WebhookEvent
impl Sync for WebhookEvent
impl Unpin for WebhookEvent
impl UnwindSafe for WebhookEvent
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