pub struct Builder {
pub options: Options,
/* private fields */
}
Expand description
Builder is used to create templates for new events, specifying default fields and override settings.
Fields§
§options: Options
Client Options
Implementations§
Source§impl Builder
impl Builder
Sourcepub fn new(options: Options) -> Self
pub fn new(options: Options) -> Self
Creates a new event Builder with emtpy Static or Dynamic fields.
Sourcepub fn add_dynamic_field(&mut self, name: &str, func: DynamicFieldFunc)
pub fn add_dynamic_field(&mut self, name: &str, func: DynamicFieldFunc)
add_dynamic_field adds a dynamic field to the builder. Any events created from this builder will get this metric added.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Builder
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)