Class DependencyVersionChange
A NuGet dependency of a project whose restored version differs from the one the session loaded: a Stride package (one shipping a .sdpkg) of another version, or a library the container loaded from another version's file.
public sealed class DependencyVersionChange
- Inheritance
-
objectDependencyVersionChange
- Extension Methods
Remarks
Apply() switches what the session knows of the dependency; reloading PackageAssemblies from their new file and the assemblies that reference the dependency completes the change.
Properties
Blocker
Why the new version can't replace the loaded one in this session, or null when it can.
public string? Blocker { get; }
Property Value
Dependency
The dependency as the project now restores it.
public Dependency Dependency { get; }
Property Value
Libraries
The library's assemblies the container loaded from another version, and the file of the new one.
public List<(LoadedAssembly LoadedAssembly, string NewPath)> Libraries { get; }
Property Value
- List<(LoadedAssembly LoadedAssembly, string NewPath)>
OldAssemblyPaths
The files of the version the session knew, registered with the container.
public List<string> OldAssemblyPaths { get; }
Property Value
Package
The session's package of that name for a Stride package; null for a library.
public Package? Package { get; }
Property Value
PackageAssemblies
The loaded assemblies of Package, and the file of the new version each one loads from.
public List<(PackageLoadedAssembly LoadedAssembly, string NewPath)> PackageAssemblies { get; }
Property Value
Session
public PackageSession Session { get; }
Property Value
Methods
Apply()
Makes the session use the new version: the container knows the new files instead of the old ones, the package takes the new version and assembly list, and a library's loaded copy leaves the container, so that a reference to it loads the new file.
public void Apply()
Revert()
Undoes Apply().
public void Revert()
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.