Trait ProfileSource
pub trait ProfileSource:
Send
+ Sync
+ 'static {
// Required method
fn select_profile(
&self,
request: &SelectionRequest,
seed: ProfileSeed,
key: DrawKey,
) -> Result<SelectedProfile, SelectionError>;
}Available on crate features
std and ua only.Expand description
Source of captured profiles for ProfileEmulateLayer.
UserAgentDatabase is the reference implementation; a single profile is a
one-entry database. Custom sources can route requests to different databases.
Required Methods§
fn select_profile(
&self,
request: &SelectionRequest,
seed: ProfileSeed,
key: DrawKey,
) -> Result<SelectedProfile, SelectionError>
fn select_profile( &self, request: &SelectionRequest, seed: ProfileSeed, key: DrawKey, ) -> Result<SelectedProfile, SelectionError>
Draw a profile for one request flow.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".