pub trait ResolveOriginExt: Send {
// Required methods
fn resolve_asset(
self: Vc<Self>,
request: Vc<Request>,
options: Vc<ResolveOptions>,
reference_type: Value<ReferenceType>,
) -> impl Future<Output = Result<Vc<ModuleResolveResult>>> + Send;
fn resolve_options(
self: Vc<Self>,
reference_type: Value<ReferenceType>,
) -> Vc<ResolveOptions>;
fn with_transition(
self: ResolvedVc<Self>,
transition: RcStr,
) -> Vc<Box<dyn ResolveOrigin>>;
}
Required Methods§
Sourcefn resolve_asset(
self: Vc<Self>,
request: Vc<Request>,
options: Vc<ResolveOptions>,
reference_type: Value<ReferenceType>,
) -> impl Future<Output = Result<Vc<ModuleResolveResult>>> + Send
fn resolve_asset( self: Vc<Self>, request: Vc<Request>, options: Vc<ResolveOptions>, reference_type: Value<ReferenceType>, ) -> impl Future<Output = Result<Vc<ModuleResolveResult>>> + Send
Resolve to an asset from that origin. Custom resolve options can be
passed. Otherwise provide origin.resolve_options()
unmodified.
Sourcefn resolve_options(
self: Vc<Self>,
reference_type: Value<ReferenceType>,
) -> Vc<ResolveOptions>
fn resolve_options( self: Vc<Self>, reference_type: Value<ReferenceType>, ) -> Vc<ResolveOptions>
Get the resolve options that apply for this origin.
Sourcefn with_transition(
self: ResolvedVc<Self>,
transition: RcStr,
) -> Vc<Box<dyn ResolveOrigin>>
fn with_transition( self: ResolvedVc<Self>, transition: RcStr, ) -> Vc<Box<dyn ResolveOrigin>>
Adds a transition that is used for resolved assets.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.