Struct tantivy::fastfield::FastFieldReaders
source · pub struct FastFieldReaders { /* private fields */ }
Expand description
Provides access to all of the BitpackedFastFieldReader.
Internally, FastFieldReaders
have preloaded fast field readers,
and just wraps several HashMap
.
Implementations§
source§impl FastFieldReaders
impl FastFieldReaders
sourcepub fn column_opt<T>(&self, field_name: &str) -> Result<Option<Column<T>>>
pub fn column_opt<T>(&self, field_name: &str) -> Result<Option<Column<T>>>
Returns a typed column associated to a given field name.
If no column associated with that field_name exists,
or existing columns do not have the required type,
returns None
.
sourcepub fn column_num_bytes(&self, field: &str) -> Result<ByteCount>
pub fn column_num_bytes(&self, field: &str) -> Result<ByteCount>
Returns the number of bytes
associated with a column.
Returns 0 if the column does not exist.
sourcepub fn column_first_or_default<T>(
&self,
field: &str
) -> Result<Arc<dyn ColumnValues<T>>>where
T: PartialOrd + Copy + HasAssociatedColumnType + Send + Sync + 'static,
DynamicColumn: Into<Option<Column<T>>>,
pub fn column_first_or_default<T>(
&self,
field: &str
) -> Result<Arc<dyn ColumnValues<T>>>where
T: PartialOrd + Copy + HasAssociatedColumnType + Send + Sync + 'static,
DynamicColumn: Into<Option<Column<T>>>,
Returns a typed column value object.
In that column value:
- Rows with no value are associated with the default value.
- Rows with several values are associated with the first value.
sourcepub fn u64(&self, field: &str) -> Result<Column<u64>>
pub fn u64(&self, field: &str) -> Result<Column<u64>>
Returns the u64
fast field reader reader associated with field
.
If field
is not a u64 fast field, this method returns an Error.
sourcepub fn date(&self, field: &str) -> Result<Column<DateTime>>
pub fn date(&self, field: &str) -> Result<Column<DateTime>>
Returns the date
fast field reader reader associated with field
.
If field
is not a date fast field, this method returns an Error.
sourcepub fn ip_addr(&self, field: &str) -> Result<Column<Ipv6Addr>>
pub fn ip_addr(&self, field: &str) -> Result<Column<Ipv6Addr>>
Returns the ip
fast field reader reader associated to field
.
If field
is not a u128 fast field, this method returns an Error.
sourcepub fn dynamic_column_handle(
&self,
field_name: &str,
column_type: ColumnType
) -> Result<Option<DynamicColumnHandle>>
pub fn dynamic_column_handle( &self, field_name: &str, column_type: ColumnType ) -> Result<Option<DynamicColumnHandle>>
Returning a dynamic_column_handle
.
sourcepub fn dynamic_column_handles(
&self,
field_name: &str
) -> Result<Vec<DynamicColumnHandle>>
pub fn dynamic_column_handles( &self, field_name: &str ) -> Result<Vec<DynamicColumnHandle>>
Returning all dynamic_column_handle
.
sourcepub fn i64(&self, field_name: &str) -> Result<Column<i64>>
pub fn i64(&self, field_name: &str) -> Result<Column<i64>>
Returns the i64
fast field reader reader associated with field
.
If field
is not a i64 fast field, this method returns an Error.
Trait Implementations§
source§impl Clone for FastFieldReaders
impl Clone for FastFieldReaders
source§fn clone(&self) -> FastFieldReaders
fn clone(&self) -> FastFieldReaders
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl Freeze for FastFieldReaders
impl !RefUnwindSafe for FastFieldReaders
impl Send for FastFieldReaders
impl Sync for FastFieldReaders
impl Unpin for FastFieldReaders
impl !UnwindSafe for FastFieldReaders
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
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.