Class LoadedAssemblyTracker
Centralized registry of byte-loaded assemblies across all Tsak loading paths.
Prevents type identity split-brain: the same assembly name always resolves to
the same instance regardless of which module loaded it first.
Provides a single Default.Resolving handler that serves all callers:
, ,
, and bare-DLL discovery.
public static class LoadedAssemblyTracker
Inheritance
Properties
Methods
EnsureResolverRegistered()
Registers the single Default.Resolving handler.
public static void EnsureResolverRegistered()
LoadOrReuse(string, byte[], ILogger?)
Returns an already-tracked assembly with the given name, the host's own instance when the host
public static Assembly LoadOrReuse(string assemblyName, byte[] bytes, ILogger? logger = null)
Replace(string, byte[])
Force-replaces the tracked assembly with a newly loaded one.
public static Assembly Replace(string assemblyName, byte[] bytes)
Track(Assembly)
Tracks an assembly loaded externally (e.g. by
public static void Track(Assembly assembly)
TrackOrReplace(Assembly)
Tracks an assembly, replacing if already present.
public static void TrackOrReplace(Assembly assembly)
TryGet(string, out Assembly?)
Tries to find a tracked assembly by name.
public static bool TryGet(string assemblyName, out Assembly? assembly)