Struct MmdbFileConfig
pub struct MmdbFileConfig { /* private fields */ }net only.Expand description
Configuration of an MmdbFileReader.
Implementations§
§impl MmdbFileConfig
impl MmdbFileConfig
pub fn with_cache(self, cache: BlockCacheConfig) -> MmdbFileConfig
pub fn with_cache(self, cache: BlockCacheConfig) -> MmdbFileConfig
Block cache of each loaded version (default: no cache).
pub fn set_cache(&mut self, cache: BlockCacheConfig) -> &mut MmdbFileConfig
pub fn set_cache(&mut self, cache: BlockCacheConfig) -> &mut MmdbFileConfig
Block cache of each loaded version (default: no cache).
pub fn with_check_interval(self, check_interval: Duration) -> MmdbFileConfig
pub fn with_check_interval(self, check_interval: Duration) -> MmdbFileConfig
How often a lookup checks whether the path names a different file (default 60 s). Zero checks on every lookup.
pub fn set_check_interval(
&mut self,
check_interval: Duration,
) -> &mut MmdbFileConfig
pub fn set_check_interval( &mut self, check_interval: Duration, ) -> &mut MmdbFileConfig
How often a lookup checks whether the path names a different file (default 60 s). Zero checks on every lookup.
pub fn with_jump_table(self, jump_table: bool) -> MmdbFileConfig
pub fn with_jump_table(self, jump_table: bool) -> MmdbFileConfig
Whether to build the 16-bit jump table per loaded version (default
on); see MmdbReader::without_jump_table for its cost.
pub fn set_jump_table(&mut self, jump_table: bool) -> &mut MmdbFileConfig
pub fn set_jump_table(&mut self, jump_table: bool) -> &mut MmdbFileConfig
Whether to build the 16-bit jump table per loaded version (default
on); see MmdbReader::without_jump_table for its cost.
pub fn maybe_with_handles(
self,
handles: Option<NonZero<usize>>,
) -> MmdbFileConfig
pub fn maybe_with_handles( self, handles: Option<NonZero<usize>>, ) -> MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
pub fn maybe_set_handles(
&mut self,
handles: Option<NonZero<usize>>,
) -> &mut MmdbFileConfig
pub fn maybe_set_handles( &mut self, handles: Option<NonZero<usize>>, ) -> &mut MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
pub fn with_handles(self, handles: NonZero<usize>) -> MmdbFileConfig
pub fn with_handles(self, handles: NonZero<usize>) -> MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
pub fn set_handles(&mut self, handles: NonZero<usize>) -> &mut MmdbFileConfig
pub fn set_handles(&mut self, handles: NonZero<usize>) -> &mut MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
pub fn without_handles(self) -> MmdbFileConfig
pub fn without_handles(self) -> MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
pub fn unset_handles(&mut self) -> &mut MmdbFileConfig
pub fn unset_handles(&mut self) -> &mut MmdbFileConfig
File handles per loaded version; None uses the default of
ReadAtFiles::open.
Trait Implementations§
§impl Clone for MmdbFileConfig
impl Clone for MmdbFileConfig
§fn clone(&self) -> MmdbFileConfig
fn clone(&self) -> MmdbFileConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more§impl Debug for MmdbFileConfig
impl Debug for MmdbFileConfig
§impl Default for MmdbFileConfig
impl Default for MmdbFileConfig
§fn default() -> MmdbFileConfig
fn default() -> MmdbFileConfig
Auto Trait Implementations§
impl Forget for MmdbFileConfig
impl Freeze for MmdbFileConfig
impl RefUnwindSafe for MmdbFileConfig
impl Send for MmdbFileConfig
impl Sync for MmdbFileConfig
impl Unpin for MmdbFileConfig
impl UnsafeUnpin for MmdbFileConfig
impl UnwindSafe for MmdbFileConfig
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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,
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a rama_grpc::Request§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§fn and<P, B, E>(self, other: P) -> And<T, P>
fn and<P, B, E>(self, other: P) -> And<T, P>
Policy that returns Action::Follow only if self and other return
Action::Follow. Read more