pub enum OwnershipError {
NetworkError(String),
ParseError(String),
ApiError(String),
NotFound(String),
RateLimited,
}Expand description
Error types that can occur during ASN and organization lookups
Variants§
NetworkError(String)
Represents network-related errors during ownership lookups.
This includes connection failures, DNS issues, or timeouts.
ParseError(String)
Indicates that the response from an ownership lookup couldn’t be parsed.
This typically occurs when an API returns data in an unexpected format.
ApiError(String)
Represents errors returned by external APIs during ownership lookups.
This could include authentication failures or invalid request errors.
NotFound(String)
Indicates that requested ownership information was not found.
This can occur when looking up ASN/organization information for an IP that isn’t allocated or isn’t in the database.
RateLimited
Indicates that requests are being rate-limited by an external API.
This typically requires waiting before making additional requests.
Trait Implementations§
Source§impl Debug for OwnershipError
impl Debug for OwnershipError
Source§impl Display for OwnershipError
impl Display for OwnershipError
Source§impl Error for OwnershipError
impl Error for OwnershipError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()