Class Arg
- Namespace
- ZeroInstall.Model
- Assembly
- ZeroInstall.Model.dll
A single command-line arguments to be passed to an executable.
[Serializable]
[Equatable]
public class Arg : ArgBase, IEquatable<XmlUnknown>, IEquatable<FeedElement>, ICloneable<ArgBase>, ICloneable<Arg>, IEquatable<Arg>
- Inheritance
-
Arg
- Implements
- Inherited Members
Properties
Value
A single command-line arguments to be passed to an executable. Will be automatically escaped to allow proper concatenation of multiple arguments containing spaces.
public required string Value { get; set; }
Property Value
Methods
Clone()
Creates a deep copy of this Arg instance.
public override ArgBase Clone()
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(Arg?)
protected bool Equals(Arg? other)
Parameters
other
Arg
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
Normalize()
Converts legacy elements, sets default values, etc..
public override void Normalize()
Exceptions
- InvalidDataException
A required property is not set or invalid.
ToString()
Returns Value. Not safe for parsing!
public override string ToString()
Returns
Operators
operator ==(Arg?, Arg?)
Indicates whether the object on the left is equal to the object on the right.
public static bool operator ==(Arg? left, Arg? right)
Parameters
Returns
- bool
true if the objects are equal; otherwise, false.
implicit operator Arg(string)
Convenience cast for turning strings into plain Args.
public static implicit operator Arg(string value)
Parameters
value
string
Returns
operator !=(Arg?, Arg?)
Indicates whether the object on the left is not equal to the object on the right.
public static bool operator !=(Arg? left, Arg? right)
Parameters
Returns
- bool
true if the objects are not equal; otherwise, false.