[][src]Struct stellar_base::time_bounds::TimeBounds

pub struct TimeBounds { /* fields omitted */ }

The time window in which a transaction is considered valid.

Implementations

impl TimeBounds[src]

pub fn valid_for(duration: Duration) -> TimeBounds[src]

Returns time bounds with the upper bounds set to duration in the future.

pub fn always_valid() -> TimeBounds[src]

Returns time bounds such that the transaction is always valid.

pub fn with_lower(&self, lower: DateTime<Utc>) -> Result<TimeBounds>[src]

Makes a new time bounds with the lower bound changed.

pub fn with_upper(&self, upper: DateTime<Utc>) -> Result<TimeBounds>[src]

Makes a new time bounds with the upper bound changed.

pub fn lower(&self) -> &Option<DateTime<Utc>>[src]

Retrieves the time bounds lower bound.

pub fn lower_mut(&mut self) -> &mut Option<DateTime<Utc>>[src]

Retrieves a mutable reference to the time bounds lower bound.

pub fn upper(&self) -> &Option<DateTime<Utc>>[src]

Retrieves the time bounds lower bound.

pub fn upper_mut(&mut self) -> &mut Option<DateTime<Utc>>[src]

Retrieves a mutable reference to the time bounds lower bound.

pub fn to_xdr(&self) -> Result<TimeBounds>[src]

Returns the xdr object.

pub fn from_xdr(x: &TimeBounds) -> Result<TimeBounds>[src]

Creates from the xdr object.

Trait Implementations

impl Clone for TimeBounds[src]

impl Debug for TimeBounds[src]

impl Eq for TimeBounds[src]

impl PartialEq<TimeBounds> for TimeBounds[src]

impl StructuralEq for TimeBounds[src]

impl StructuralPartialEq for TimeBounds[src]

impl XDRDeserialize for TimeBounds[src]

impl XDRSerialize for TimeBounds[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> From<T> for T[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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.