[][src]Struct nakadion::consumer::BatchTimespanSecs

pub struct BatchTimespanSecs(_);

Useful for batching events based on their received_at timestamp.

Methods

impl BatchTimespanSecs[src]

impl BatchTimespanSecs[src]

pub fn try_from_env() -> Result<Option<BatchTimespanSecs>, Error>[src]

Initialize from the environment.

Returns None if the value was not found and fails if the value could not be parsed.

The name of the environment variable is "NAKADION_ BATCH_TIMESPAN_SECS "

pub fn try_from_env_prefixed<T>(
    prefix: T
) -> Result<Option<BatchTimespanSecs>, Error> where
    T: Into<String>, 
[src]

Initialize from the environment.

Returns None if the value was not found and fails if the value could not be parsed.

The name of the environment variable is "prefix_ BATCH_TIMESPAN_SECS "

pub fn try_from_env_named<T>(
    var_name: T
) -> Result<Option<BatchTimespanSecs>, Error> where
    T: AsRef<str>, 
[src]

Initialize from the environment.

Returns None if the value was not found and fails if the value could not be parsed.

The name of the environment variable is var_name.

pub fn from_env() -> Result<BatchTimespanSecs, Error>[src]

Initialize from the environment.

Fails if the value was not found or if the value could not be parsed.

The name of the environment variable is "NAKADION_ BATCH_TIMESPAN_SECS "

pub fn from_env_prefixed<T>(prefix: T) -> Result<BatchTimespanSecs, Error> where
    T: Into<String>, 
[src]

Initialize from the environment.

Fails if the value was not found or if the value could not be parsed.

The name of the environment variable is "prefix_ BATCH_TIMESPAN_SECS "

pub fn from_env_named<T>(var_name: T) -> Result<BatchTimespanSecs, Error> where
    T: AsRef<str>, 
[src]

Initialize from the environment.

Fails if the value was not found or if the value could not be parsed.

The name of the environment variable is var_name.

pub fn from_env_opt() -> Option<BatchTimespanSecs>[src]

Initialize from the environment.

Returns None if the value could not be read for any reason.

The name of the environment variable is "NAKADION_ BATCH_TIMESPAN_SECS "

pub fn from_env_opt_prefixed<T>(prefix: T) -> Option<BatchTimespanSecs> where
    T: Into<String>, 
[src]

Initialize from the environment.

Returns None if the value could not be read for any reason.

The name of the environment variable is "prefix_ BATCH_TIMESPAN_SECS "

pub fn from_env_opt_named<T>(var_name: T) -> Option<BatchTimespanSecs> where
    T: AsRef<str>, 
[src]

Initialize from the environment.

Returns None if the value could not be read for any reason.

The name of the environment variable is var_name.

impl BatchTimespanSecs[src]

pub fn new<T>(v: T) -> BatchTimespanSecs where
    T: Into<u32>, 
[src]

impl BatchTimespanSecs[src]

pub fn into_inner(self) -> u32[src]

Trait Implementations

impl Clone for BatchTimespanSecs[src]

impl Copy for BatchTimespanSecs[src]

impl Debug for BatchTimespanSecs[src]

impl<'de> Deserialize<'de> for BatchTimespanSecs[src]

impl Display for BatchTimespanSecs[src]

impl Eq for BatchTimespanSecs[src]

impl From<u32> for BatchTimespanSecs[src]

impl FromStr for BatchTimespanSecs[src]

type Err = Error

The associated error which can be returned from parsing.

impl PartialEq<BatchTimespanSecs> for BatchTimespanSecs[src]

impl Serialize for BatchTimespanSecs[src]

impl StructuralEq for BatchTimespanSecs[src]

impl StructuralPartialEq for BatchTimespanSecs[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,