Struct CheckConfig

Source
pub struct CheckConfig {
    pub concurrency: usize,
    pub timeout: Duration,
    pub enable_whois_fallback: bool,
    pub enable_bootstrap: bool,
    pub detailed_info: bool,
    pub tlds: Option<Vec<String>>,
    pub rdap_timeout: Duration,
    pub whois_timeout: Duration,
    pub custom_presets: HashMap<String, Vec<String>>,
}
Expand description

Configuration options for domain checking operations.

This struct allows fine-tuning of the domain checking behavior, including performance, timeout, and protocol preferences.

Fields§

§concurrency: usize

Maximum number of concurrent domain checks Default: 10, Range: 1-100

§timeout: Duration

Timeout for each individual domain check Default: 5 seconds

§enable_whois_fallback: bool

Whether to automatically fall back to WHOIS when RDAP fails Default: true

§enable_bootstrap: bool

Whether to use IANA bootstrap registry for unknown TLDs Default: false (uses built-in registry only)

§detailed_info: bool

Whether to extract detailed domain information for taken domains Default: false (just availability status)

§tlds: Option<Vec<String>>

List of TLDs to check for base domain names If None, defaults to [“com”]

§rdap_timeout: Duration

Custom timeout for RDAP requests (separate from overall timeout) Default: 3 seconds

§whois_timeout: Duration

Custom timeout for WHOIS requests Default: 5 seconds

§custom_presets: HashMap<String, Vec<String>>

Custom user-defined TLD presets from config files Default: empty

Implementations§

Source§

impl CheckConfig

Source

pub fn with_concurrency(self, concurrency: usize) -> Self

Create a new configuration with custom concurrency.

Automatically caps concurrency at 100 to prevent resource exhaustion.

Source

pub fn with_timeout(self, timeout: Duration) -> Self

Set custom timeout for domain checks.

Source

pub fn with_whois_fallback(self, enabled: bool) -> Self

Enable or disable WHOIS fallback.

Source

pub fn with_bootstrap(self, enabled: bool) -> Self

Enable or disable IANA bootstrap registry.

Source

pub fn with_detailed_info(self, enabled: bool) -> Self

Enable detailed domain information extraction.

Source

pub fn with_tlds(self, tlds: Vec<String>) -> Self

Set TLDs to check for base domain names.

Trait Implementations§

Source§

impl Clone for CheckConfig

Source§

fn clone(&self) -> CheckConfig

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 Debug for CheckConfig

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for CheckConfig

Source§

fn default() -> Self

Create a sensible default configuration.

These defaults are chosen to work well for most use cases while being conservative about resource usage.

Source§

impl<'de> Deserialize<'de> for CheckConfig

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for CheckConfig

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

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<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<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> 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.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,