pub struct LiteLoaderAddon { /* private fields */ }Expand description
Composable LiteLoader addon supporting Vanilla and Forge host instances.
Implementations§
Source§impl LiteLoaderAddon
impl LiteLoaderAddon
Sourcepub fn new(source: LiteLoaderSource) -> Self
pub fn new(source: LiteLoaderSource) -> Self
Creates a LiteLoaderAddon backed by the given metadata/version source.
Sourcepub fn with_http_client(self, client: SwappableClient) -> Self
pub fn with_http_client(self, client: SwappableClient) -> Self
Replaces the SwappableClient used by the underlying LiteLoaderSource.
Trait Implementations§
Source§impl Addon for LiteLoaderAddon
impl Addon for LiteLoaderAddon
Source§fn descriptor(&self) -> AddonDescriptor
fn descriptor(&self) -> AddonDescriptor
Returns the addon’s unique identifier and display name.
Source§fn supported_game_versions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<GameVersion>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn supported_game_versions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<GameVersion>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns supported game versions when this addon exposes a remote catalog.
Source§fn available_versions<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 AddonCatalogQuery<'life2>,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<AddonRelease>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn available_versions<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
query: &'life1 AddonCatalogQuery<'life2>,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<AddonRelease>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Returns available addon releases for a host driver and game version, or
None when this addon does not provide a version catalog.Source§fn check_compatibility(&self, ctx: &AddonContext<'_>) -> AddonCompatibility
fn check_compatibility(&self, ctx: &AddonContext<'_>) -> AddonCompatibility
Checks whether this addon is compatible with the host driver and game version.
Source§fn inspect<'life0, 'life1, 'async_trait>(
&'life0 self,
probe: &'life1 InstanceProbe,
) -> Pin<Box<dyn Future<Output = Result<Option<InstalledAddon>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn inspect<'life0, 'life1, 'async_trait>(
&'life0 self,
probe: &'life1 InstanceProbe,
) -> Pin<Box<dyn Future<Output = Result<Option<InstalledAddon>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Detects whether an unmanaged/external copy of this addon is already present in
probe.Source§fn prepare<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
request: &'life1 AddonPrepareRequest<'life2>,
) -> Pin<Box<dyn Future<Output = Result<AddonPrepareOutput>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn prepare<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
request: &'life1 AddonPrepareRequest<'life2>,
) -> Pin<Box<dyn Future<Output = Result<AddonPrepareOutput>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Downloads any required artifacts and produces the metadata patch and managed files
to persist for this addon.
Source§fn patch_mode_support(&self) -> PatchModeSupport
fn patch_mode_support(&self) -> PatchModeSupport
Declares which patch modes this addon supports.
Source§fn requires_runtime_hook(&self) -> bool
fn requires_runtime_hook(&self) -> bool
Returns
true when this addon requires code execution during launch
command construction (augment_launch) and cannot degrade to data-only.Source§fn augment_launch<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_args: &'life1 mut AddonLaunchArgs,
_ctx: &'life2 AddonLaunchContext<'life3>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn augment_launch<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_args: &'life1 mut AddonLaunchArgs,
_ctx: &'life2 AddonLaunchContext<'life3>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Augments the launch command with dynamic JVM or game arguments before spawning.
Source§impl Clone for LiteLoaderAddon
impl Clone for LiteLoaderAddon
Source§impl Debug for LiteLoaderAddon
impl Debug for LiteLoaderAddon
Auto Trait Implementations§
impl Forget for LiteLoaderAddon
impl Freeze for LiteLoaderAddonwhere
*const ArcInner<RwLock<ClientState>> is !null: Freeze,
PhantomData<ArcInner<RwLock<ClientState>>>: Freeze,
*const [Pos] is !null: Freeze,
PhantomData<[Pos]>: Freeze,
*const u8 is !null: Freeze,
PhantomData<Bucket<HeaderValue>>: Freeze,
PhantomData<ExtraValue<HeaderValue>>: Freeze,
PhantomData<(String, Url)>: Freeze,
impl Move for LiteLoaderAddon
impl RefUnwindSafe for LiteLoaderAddonwhere
Atomic<usize>: RefUnwindSafe,
RwLock<ClientState>: RefUnwindSafe,
Atomic<*mut ()>: RefUnwindSafe,
impl Send for LiteLoaderAddon
impl Sync for LiteLoaderAddon
impl Unpin for LiteLoaderAddon
impl UnsafeUnpin for LiteLoaderAddonwhere
*const ArcInner<RwLock<ClientState>> is !null: UnsafeUnpin,
PhantomData<ArcInner<RwLock<ClientState>>>: UnsafeUnpin,
*const [Pos] is !null: UnsafeUnpin,
PhantomData<[Pos]>: UnsafeUnpin,
*const u8 is !null: UnsafeUnpin,
PhantomData<Bucket<HeaderValue>>: UnsafeUnpin,
PhantomData<ExtraValue<HeaderValue>>: UnsafeUnpin,
PhantomData<(String, Url)>: UnsafeUnpin,
impl UnwindSafe for LiteLoaderAddonwhere
Arc<RwLock<ClientState>>: UnwindSafe,
BoxRaw<[Pos]>: UnwindSafe,
RawVecInner: UnwindSafe,
*const u8: UnwindSafe,
Align8<*mut ()>: UnwindSafe,
&'static Vtable: UnwindSafe,
Blanket Implementations§
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
Mutably borrows from an owned value. Read more