Trait TimeIndexOps

Source
pub trait TimeIndexOps: Send + Sync {
    type IndexType: AsTime;
    type RangeType<'a>: TimeIndexOps<IndexType = Self::IndexType> + 'a
       where Self: 'a;

    // Required methods
    fn active(&self, w: Range<Self::IndexType>) -> bool;
    fn range(&self, w: Range<Self::IndexType>) -> Self::RangeType<'_>;
    fn first(&self) -> Option<Self::IndexType>;
    fn last(&self) -> Option<Self::IndexType>;
    fn iter(&self) -> Box<dyn Iterator<Item = Self::IndexType> + Send + '_>;
    fn len(&self) -> usize;

    // Provided methods
    fn active_t(&self, w: Range<i64>) -> bool { ... }
    fn range_t(&self, w: Range<i64>) -> Self::RangeType<'_> { ... }
    fn first_t(&self) -> Option<i64> { ... }
    fn last_t(&self) -> Option<i64> { ... }
    fn iter_t(&self) -> Box<dyn Iterator<Item = i64> + Send + '_> { ... }
}

Required Associated Types§

Source

type IndexType: AsTime

Source

type RangeType<'a>: TimeIndexOps<IndexType = Self::IndexType> + 'a where Self: 'a

Required Methods§

Source

fn active(&self, w: Range<Self::IndexType>) -> bool

Source

fn range(&self, w: Range<Self::IndexType>) -> Self::RangeType<'_>

Source

fn first(&self) -> Option<Self::IndexType>

Source

fn last(&self) -> Option<Self::IndexType>

Source

fn iter(&self) -> Box<dyn Iterator<Item = Self::IndexType> + Send + '_>

Source

fn len(&self) -> usize

Provided Methods§

Source

fn active_t(&self, w: Range<i64>) -> bool

Source

fn range_t(&self, w: Range<i64>) -> Self::RangeType<'_>

Source

fn first_t(&self) -> Option<i64>

Source

fn last_t(&self) -> Option<i64>

Source

fn iter_t(&self) -> Box<dyn Iterator<Item = i64> + Send + '_>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§