pub struct FirestoreIndexParams {
pub collection_group: FirestoreCollectionId,
pub composite_indexes: Vec<FirestoreCompositeIndex>,
pub field_overrides: Vec<FirestoreFieldOverride>,
pub ttl_fields: Vec<String>,
}Expand description
One collection group’s declared composite indexes, single-field overrides and TTL policy.
A statement owns exactly this one collection group: FirestoreIndexSyncOptions::prune
never reaches an index, override or TTL field on any other group. Several groups need
several statements.
Fields§
§collection_group: FirestoreCollectionIdThe collection group this statement owns.
composite_indexes: Vec<FirestoreCompositeIndex>The declared composite indexes.
field_overrides: Vec<FirestoreFieldOverride>The declared single-field index overrides.
ttl_fields: Vec<String>The field paths whose timestamp should enable document TTL.
Implementations§
Source§impl FirestoreIndexParams
impl FirestoreIndexParams
Sourcepub fn new(collection_group: FirestoreCollectionId) -> Self
pub fn new(collection_group: FirestoreCollectionId) -> Self
Creates a new FirestoreIndexParams from its required fields. Option fields start as None, and fields with #[default] take their default.
Sourcepub fn collection_group(&mut self, value: FirestoreCollectionId) -> &mut Self
pub fn collection_group(&mut self, value: FirestoreCollectionId) -> &mut Self
Sets collection_group to value.
The collection group this statement owns.
Sourcepub fn with_collection_group(self, value: FirestoreCollectionId) -> Self
pub fn with_collection_group(self, value: FirestoreCollectionId) -> Self
Returns self with collection_group set to value.
The collection group this statement owns.
Sourcepub fn composite_indexes(
&mut self,
value: Vec<FirestoreCompositeIndex>,
) -> &mut Self
pub fn composite_indexes( &mut self, value: Vec<FirestoreCompositeIndex>, ) -> &mut Self
Sets composite_indexes to value.
The declared composite indexes.
Sourcepub fn with_composite_indexes(self, value: Vec<FirestoreCompositeIndex>) -> Self
pub fn with_composite_indexes(self, value: Vec<FirestoreCompositeIndex>) -> Self
Returns self with composite_indexes set to value.
The declared composite indexes.
Sourcepub fn field_overrides(
&mut self,
value: Vec<FirestoreFieldOverride>,
) -> &mut Self
pub fn field_overrides( &mut self, value: Vec<FirestoreFieldOverride>, ) -> &mut Self
Sets field_overrides to value.
The declared single-field index overrides.
Sourcepub fn with_field_overrides(self, value: Vec<FirestoreFieldOverride>) -> Self
pub fn with_field_overrides(self, value: Vec<FirestoreFieldOverride>) -> Self
Returns self with field_overrides set to value.
The declared single-field index overrides.
Sourcepub fn ttl_fields(&mut self, value: Vec<String>) -> &mut Self
pub fn ttl_fields(&mut self, value: Vec<String>) -> &mut Self
Sets ttl_fields to value.
The field paths whose timestamp should enable document TTL.
Sourcepub fn with_ttl_fields(self, value: Vec<String>) -> Self
pub fn with_ttl_fields(self, value: Vec<String>) -> Self
Returns self with ttl_fields set to value.
The field paths whose timestamp should enable document TTL.
Trait Implementations§
Source§impl Clone for FirestoreIndexParams
impl Clone for FirestoreIndexParams
Source§impl Debug for FirestoreIndexParams
impl Debug for FirestoreIndexParams
Source§impl From<FirestoreIndexParamsInit> for FirestoreIndexParams
impl From<FirestoreIndexParamsInit> for FirestoreIndexParams
Source§fn from(value: FirestoreIndexParamsInit) -> Self
fn from(value: FirestoreIndexParamsInit) -> Self
Source§impl PartialEq for FirestoreIndexParams
impl PartialEq for FirestoreIndexParams
impl StructuralPartialEq for FirestoreIndexParams
Auto Trait Implementations§
impl Freeze for FirestoreIndexParams
impl RefUnwindSafe for FirestoreIndexParams
impl Send for FirestoreIndexParams
impl Sync for FirestoreIndexParams
impl Unpin for FirestoreIndexParams
impl UnsafeUnpin for FirestoreIndexParams
impl UnwindSafe for FirestoreIndexParams
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request