Skip to main content

AssetLoader Class

Loads assets compiled into the application binary.

Definition

Namespace: Avalonia.Platform
Assembly: Avalonia.Base (in Avalonia.Base.dll)

public static class AssetLoader
View Source
InheritanceObject → AssetLoader

Methods

Exists(Uri, Uri)Checks if an asset with the specified URI exists.
GetAssembly(Uri, Uri)Extracts assembly information from URI
GetAssets(Uri, Uri)Gets all assets of a folder and subfolders that match specified uri.
InvalidateAssemblyCache()Removes the assembly from the cache.
InvalidateAssemblyCache(String)Removes all assemblies from the cache.
Open(Uri, Uri)Opens the asset with the requested URI.
OpenAndGetAssembly(Uri, Uri)Opens the asset with the requested URI and returns the asset stream and the assembly containing the asset.
SetDefaultAssembly(Assembly)We need a way to override the default assembly selected by the host platform because right now it is selecting the wrong one for PCL based Apps. The AssetLoader needs a refactor cause right now it lives in 3+ platforms which can all be loaded on Windows.

See Also

Reference

Avalonia.Platform Namespace