Struct hubcaps::hooks::HookEditOptionsBuilder
source · pub struct HookEditOptionsBuilder(_);
Implementations
sourceimpl HookEditOptionsBuilder
impl HookEditOptionsBuilder
pub fn active(&mut self, active: bool) -> &mut Self
sourcepub fn events<E>(&mut self, events: Vec<E>) -> &mut Selfwhere
E: Into<String>,
pub fn events<E>(&mut self, events: Vec<E>) -> &mut Selfwhere
E: Into<String>,
a list of github events this hook should receive deliveries for the default is “push”. for a full list, see the Github api docs
sourcepub fn url<U>(&mut self, url: U) -> &mut Selfwhere
U: Into<String>,
pub fn url<U>(&mut self, url: U) -> &mut Selfwhere
U: Into<String>,
web hooks must have an associated url
sourcepub fn content_type(&mut self, content_type: WebHookContentType) -> &mut Self
pub fn content_type(&mut self, content_type: WebHookContentType) -> &mut Self
web hooks can optionally specify a content_type of “form” or “json” which indicates the type of payload they will expect to receive
sourcepub fn secret<S>(&mut self, sec: S) -> &mut Selfwhere
S: Into<String>,
pub fn secret<S>(&mut self, sec: S) -> &mut Selfwhere
S: Into<String>,
web hooks can optionally provide a secret used to sign deliveries to identify that their source was indeed github
pub fn config_str_entry<K, V>(&mut self, k: K, v: V) -> &mut Selfwhere
K: Into<String>,
V: Into<String>,
pub fn config_entry<N>(&mut self, name: N, value: Value) -> &mut Selfwhere
N: Into<String>,
pub fn build(&self) -> HookEditOptions
Trait Implementations
sourceimpl Default for HookEditOptionsBuilder
impl Default for HookEditOptionsBuilder
sourcefn default() -> HookEditOptionsBuilder
fn default() -> HookEditOptionsBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for HookEditOptionsBuilder
impl Send for HookEditOptionsBuilder
impl Sync for HookEditOptionsBuilder
impl Unpin for HookEditOptionsBuilder
impl UnwindSafe for HookEditOptionsBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more