pub trait Timestamps {
    type Timestamps<'a>: GetIndex<Output = i64> + 'a
       where Self: 'a;
    type Offsets<'a>: GetIndex<Output = i16> + 'a
       where Self: 'a;

    // Required methods
    fn author_timestamp(&self) -> Self::Timestamps<'_>;
    fn author_timestamp_offset(&self) -> Self::Offsets<'_>;
    fn committer_timestamp(&self) -> Self::Timestamps<'_>;
    fn committer_timestamp_offset(&self) -> Self::Offsets<'_>;
}
Expand description

Trait for backend storage of timestamp properties (either in-memory or memory-mapped)

Required Associated Types§

source

type Timestamps<'a>: GetIndex<Output = i64> + 'a where Self: 'a

source

type Offsets<'a>: GetIndex<Output = i16> + 'a where Self: 'a

Required Methods§

source

fn author_timestamp(&self) -> Self::Timestamps<'_>

source

fn author_timestamp_offset(&self) -> Self::Offsets<'_>

source

fn committer_timestamp(&self) -> Self::Timestamps<'_>

source

fn committer_timestamp_offset(&self) -> Self::Offsets<'_>

Object Safety§

This trait is not object safe.

Implementors§

source§

impl Timestamps for MappedTimestamps

§

type Timestamps<'a> = &'a NumberMmap<BigEndian, i64, Mmap>

§

type Offsets<'a> = &'a NumberMmap<BigEndian, i16, Mmap>

source§

impl Timestamps for VecTimestamps

§

type Timestamps<'a> = &'a [i64]

§

type Offsets<'a> = &'a [i16]