Enum ComputedVec

Source
pub enum ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
where S1T: Clone, S2T: Clone, S3T: Clone,
{ Eager { vec: EagerVec<I, T>, deps: Dependencies<I, T, S1I, S1T, S2I, S2T, S3I, S3T>, }, LazyFrom1(LazyVecFrom1<I, T, S1I, S1T>), LazyFrom2(LazyVecFrom2<I, T, S1I, S1T, S2I, S2T>), LazyFrom3(LazyVecFrom3<I, T, S1I, S1T, S2I, S2T, S3I, S3T>), }

Variants§

§

Eager

Fields

§vec: EagerVec<I, T>
§deps: Dependencies<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
§

LazyFrom1(LazyVecFrom1<I, T, S1I, S1T>)

§

LazyFrom2(LazyVecFrom2<I, T, S1I, S1T, S2I, S2T>)

§

LazyFrom3(LazyVecFrom3<I, T, S1I, S1T, S2I, S2T, S3I, S3T>)

Implementations§

Source§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Source

pub fn forced_import_or_init_from_1( db: &Database, name: &str, version: Version, computation: Computation, format: Format, source: AnyBoxedIterableVec<S1I, S1T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn forced_import_or_init_from_1_with( options: ImportOptions<'_>, computation: Computation, format: Format, source: AnyBoxedIterableVec<S1I, S1T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn forced_import_or_init_from_2( db: &Database, name: &str, version: Version, computation: Computation, format: Format, source1: AnyBoxedIterableVec<S1I, S1T>, source2: AnyBoxedIterableVec<S2I, S2T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>, &mut dyn BaseVecIterator<Item = (S2I, Cow<'a, S2T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn forced_import_or_init_from_2_with( options: ImportOptions<'_>, computation: Computation, format: Format, source1: AnyBoxedIterableVec<S1I, S1T>, source2: AnyBoxedIterableVec<S2I, S2T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>, &mut dyn BaseVecIterator<Item = (S2I, Cow<'a, S2T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn forced_import_or_init_from_3( db: &Database, name: &str, version: Version, computation: Computation, format: Format, source1: AnyBoxedIterableVec<S1I, S1T>, source2: AnyBoxedIterableVec<S2I, S2T>, source3: AnyBoxedIterableVec<S3I, S3T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>, &mut dyn BaseVecIterator<Item = (S2I, Cow<'a, S2T>)>, &mut dyn BaseVecIterator<Item = (S3I, Cow<'a, S3T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn forced_import_or_init_from_3_with( options: ImportOptions<'_>, computation: Computation, format: Format, source1: AnyBoxedIterableVec<S1I, S1T>, source2: AnyBoxedIterableVec<S2I, S2T>, source3: AnyBoxedIterableVec<S3I, S3T>, compute: for<'a> fn(I, &mut dyn BaseVecIterator<Item = (S1I, Cow<'a, S1T>)>, &mut dyn BaseVecIterator<Item = (S2I, Cow<'a, S2T>)>, &mut dyn BaseVecIterator<Item = (S3I, Cow<'a, S3T>)>) -> Option<T>, ) -> Result<Self>

Source

pub fn compute_if_necessary<T2>( &mut self, max_from: I, len_source: &impl AnyIterableVec<I, T2>, exit: &Exit, ) -> Result<()>

Trait Implementations§

Source§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> AnyCollectableVec for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Source§

fn collect_range_serde_json( &self, from: Option<usize>, to: Option<usize>, ) -> Result<Vec<Value>>

Source§

fn range_count(&self, from: Option<i64>, to: Option<i64>) -> usize

Source§

fn range_weight(&self, from: Option<i64>, to: Option<i64>) -> usize

Source§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> AnyIterableVec<I, T> for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Source§

fn boxed_iter<'a>(&'a self) -> BoxedVecIterator<'a, I, T>
where T: 'a,

Source§

fn iter<'a>(&'a self) -> BoxedVecIterator<'a, I, T>
where I: StoredIndex, T: StoredRaw + 'a,

Source§

fn iter_at<'a>(&'a self, i: I) -> BoxedVecIterator<'a, I, T>
where I: StoredIndex, T: StoredRaw + 'a,

Source§

fn iter_at_<'a>(&'a self, i: usize) -> BoxedVecIterator<'a, I, T>
where I: StoredIndex, T: StoredRaw + 'a,

Source§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> AnyVec for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Source§

fn version(&self) -> Version

Source§

fn name(&self) -> &str

Source§

fn index_type_to_string(&self) -> &'static str

Source§

fn len(&self) -> usize

Source§

fn value_type_to_size_of(&self) -> usize

Source§

fn is_empty(&self) -> bool

Source§

fn etag(&self, stamp: Stamp, to: Option<i64>) -> String

Source§

fn i64_to_usize(&self, i: i64) -> usize

Source§

impl<I: Clone, T: Clone, S1I: Clone, S1T, S2I: Clone, S2T, S3I: Clone, S3T> Clone for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
where S1T: Clone + Clone, S2T: Clone + Clone, S3T: Clone + Clone,

Source§

fn clone(&self) -> ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<'a, I, T, S1I, S1T, S2I, S2T, S3I, S3T> IntoIterator for &'a ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Source§

type Item = (I, Cow<'a, T>)

The type of the elements being iterated over.
Source§

type IntoIter = ComputedVecIterator<'a, I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Which kind of iterator are we turning this into?
Source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more

Auto Trait Implementations§

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> Freeze for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> !RefUnwindSafe for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> Send for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
where I: Send, T: Send,

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> Sync for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
where I: Sync, T: Sync,

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> Unpin for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>
where I: Unpin, T: Unpin,

§

impl<I, T, S1I, S1T, S2I, S2T, S3I, S3T> !UnwindSafe for ComputedVec<I, T, S1I, S1T, S2I, S2T, S3I, S3T>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<I, T, U> AnyCloneableIterableVec<I, T> for U
where U: 'static + AnyIterableVec<I, T> + Clone,

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<I, T, V> CollectableVec<I, T> for V
where V: AnyVec + AnyIterableVec<I, T> + Clone, I: StoredIndex, T: StoredRaw,

Source§

fn collect(&self) -> Result<Vec<T>>

Source§

fn collect_range( &self, from: Option<usize>, to: Option<usize>, ) -> Result<Vec<T>>

Source§

fn i64_to_usize_(i: i64, len: usize) -> usize

Source§

fn collect_signed_range( &self, from: Option<i64>, to: Option<i64>, ) -> Result<Vec<T>>

Source§

fn collect_range_serde_json( &self, from: Option<usize>, to: Option<usize>, ) -> Result<Vec<Value>>

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.