Class Candidate
- Namespace
- ZeroInstall.Publish.EntryPoints
- Assembly
- ZeroInstall.Publish.dll
Collects information about a potential candidate for an entry point. The subclass type determines the type of executable (native binary, interpreted script, etc.).
[Equatable]
public abstract class Candidate : IEquatable<Candidate>
- Inheritance
-
Candidate
- Implements
- Derived
- Inherited Members
Properties
Architecture
The application's target architecture.
public Architecture Architecture { get; set; }
Property Value
BaseDirectory
The base directory containing the entire application.
[Browsable(false)]
[IgnoreEquality]
protected DirectoryInfo? BaseDirectory { get; }
Property Value
Category
The main category of the application. May influence the placement in the start menu.
[TypeConverter(typeof(CategoryNameConverter))]
public string? Category { get; set; }
Property Value
CommandName
The Name used by CreateCommand().
protected string CommandName { get; }
Property Value
Name
The application's name.
public string? Name { get; set; }
Property Value
Remarks
A suggestion for Name.
NeedsTerminal
Indicates whether the application is a command-line application (true
) or a GUI application (false
).
public bool NeedsTerminal { get; set; }
Property Value
RelativePath
The path of this entry point relative to BaseDirectory.
[Browsable(false)]
public string? RelativePath { get; }
Property Value
Summary
Short one-line description; the first word should not be upper-case unless it is a proper noun (e.g. "cures all ills").
public string? Summary { get; set; }
Property Value
Remarks
A suggestion for Summaries.
Version
The application's current version.
public ImplementationVersion? Version { get; set; }
Property Value
Methods
CreateCommand()
Creates a Command to launch this entry point.
public abstract Command CreateCommand()
Returns
Equals(object?)
Determines whether the specified object is equal to the current object.
public override bool Equals(object? obj)
Parameters
obj
objectThe object to compare with the current object.
Returns
Equals(Candidate?)
protected bool Equals(Candidate? other)
Parameters
other
Candidate
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
IsExecutable(string)
Determines whether a file is executable.
protected bool IsExecutable(string path)
Parameters
path
string
Returns
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
ToVersionRange(ImplementationVersion?)
protected static VersionRange? ToVersionRange(ImplementationVersion? version)
Parameters
version
ImplementationVersion
Returns
Operators
operator ==(Candidate?, Candidate?)
Indicates whether the object on the left is equal to the object on the right.
public static bool operator ==(Candidate? left, Candidate? right)
Parameters
Returns
- bool
true if the objects are equal; otherwise, false.
operator !=(Candidate?, Candidate?)
Indicates whether the object on the left is not equal to the object on the right.
public static bool operator !=(Candidate? left, Candidate? right)
Parameters
Returns
- bool
true if the objects are not equal; otherwise, false.