[−][src]Struct tempest_source_mock::MockSource
A mock source which should be used for testing purposes. This source mocks pushing & polling messages from a queue.
Fields
queue: VecDeque<SourceMsg>
Trait Implementations
impl Default for MockSource
[src]
impl Source for MockSource
[src]
fn name(&self) -> &'static str
[src]
fn setup(&mut self) -> SourceResult<()>
[src]
fn ack(&mut self, _msg_id: MsgId) -> SourceResult<(i32, i32)>
[src]
fn batch_ack(&mut self, msgs: Vec<MsgId>) -> SourceResult<(i32, i32)>
[src]
fn max_backoff(&self) -> SourceResult<&u64>
[src]
fn ack_policy(&self) -> SourceResult<&SourceAckPolicy>
[src]
fn ack_interval(&self) -> SourceResult<&SourceInterval>
[src]
fn poll_interval(&self) -> SourceResult<&SourceInterval>
[src]
fn poll(&mut self) -> SourcePollResult
[src]
fn validate(&mut self) -> Result<(), SourceError>
[src]
fn shutdown(&mut self) -> Result<(), SourceError>
[src]
fn connect(&mut self) -> Result<(), SourceError>
[src]
fn healthy(&mut self) -> bool
[src]
fn monitor(&mut self) -> Result<(), SourceError>
[src]
fn monitor_interval(&self) -> Result<&SourceInterval, SourceError>
[src]
fn flush_metrics(&mut self)
[src]
Auto Trait Implementations
impl Unpin for MockSource
impl Sync for MockSource
impl Send for MockSource
impl UnwindSafe for MockSource
impl RefUnwindSafe for MockSource
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,