Skip to main content

UltraVibeBuilder

Struct UltraVibeBuilder 

Source
pub struct UltraVibeBuilder { /* private fields */ }
Expand description

A builder for creating an UltraVibeSystem.

This provides a flexible way to initialize the system with a custom number of normal and “super” worker nodes.

Implementations§

Source§

impl UltraVibeBuilder

Source

pub fn new() -> Self

Creates a new UltraVibeBuilder with default settings.

Source

pub fn with_nodes(self, count: usize) -> Self

Sets the total number of worker nodes for the system.

Source

pub fn with_super_nodes(self, count: usize) -> Self

Sets the number of “super” nodes within the total node count.

Super nodes are configured with higher task queue capacity and more worker threads, making them suitable for more intensive tasks.

Source

pub fn build(self) -> UltraVibeSystem

Builds and returns a fully initialized UltraVibeSystem.

This method uses the configured settings or falls back to defaults. It creates all the VibeNode instances and wires them into the system.

§Panics

Panics if the number of super nodes is greater than the total number of nodes.

Trait Implementations§

Source§

impl Default for UltraVibeBuilder

Source§

fn default() -> UltraVibeBuilder

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

Auto Trait Implementations§

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> 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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

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.