Class SelectionCandidate
- Namespace
- ZeroInstall.Model.Selection
- Assembly
- ZeroInstall.Model.dll
Represents an Implementation that is available to a solver for selection.
public sealed class SelectionCandidate : IEquatable<SelectionCandidate>
- Inheritance
-
objectSelectionCandidate
- Implements
Constructors
SelectionCandidate(FeedUri, FeedPreferences, Implementation, Requirements, bool)
Creates a new selection candidate.
public SelectionCandidate(FeedUri feedUri, FeedPreferences feedPreferences, Implementation implementation, Requirements requirements, bool offlineUncached = false)
Parameters
feedUriFeedUriThe file name or URL of the feed listing the implementation.
feedPreferencesFeedPreferencesThe FeedPreferences for FeedUri.
implementationImplementationThe implementation this selection candidate references.
requirementsRequirementsA set of requirements/restrictions the
implementationneeds to fulfill for IsSuitable to betrue.offlineUncachedboolMark this candidate as unsuitable because it is uncached and the network mode is set to offline.
Properties
Architecture
For platform-specific binaries, the platform for which an Implementation was compiled, in the form os-cpu. Either the os or cpu part may be *, which will make it available on any OS or CPU.
public string Architecture { get; }
Property Value
EffectiveStability
The UserStability if it is set, otherwise Stability.
[Browsable(false)]
public Stability EffectiveStability { get; }
Property Value
FeedPreferences
The FeedPreferences for FeedUri.
[Browsable(false)]
public FeedPreferences FeedPreferences { get; }
Property Value
FeedUri
The file name or URL of the feed listing the implementation.
public FeedUri FeedUri { get; }
Property Value
Implementation
The implementation this selection candidate references.
[Browsable(false)]
public Implementation Implementation { get; }
Property Value
IsSuitable
Indicates whether this implementation fulfills all specified Requirements.
[Browsable(false)]
public bool IsSuitable { get; }
Property Value
Notes
Human-readable notes about the implementation, e.g. "not suitable for this architecture".
public string? Notes { get; }
Property Value
Released
The date this implementation was made available. For development versions checked out from version control this attribute should not be present.
public DateTime Released { get; }
Property Value
Stability
The feed-specified stability rating for this implementation.
[UnconditionalSuppressMessage("AOT", "IL3050", Justification = "Skips part of logic when dynamic code generation is not available")]
public Stability Stability { get; }
Property Value
UserStability
A user-specified override for the Stability specified in the feed.
public Stability UserStability { get; set; }
Property Value
Version
The version number of the implementation.
public ImplementationVersion Version { get; }
Property Value
Methods
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
Equals(SelectionCandidate?)
public bool Equals(SelectionCandidate? other)
Parameters
otherSelectionCandidate
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
Returns the selection candidate in the form "SelectionCandidate: Implementation". Not safe for parsing!
public override string ToString()