Class UpdateFile
Represents a content file for an update.
Inheritance
Implements
Namespace: Microsoft.PackageGraph.MicrosoftUpdate.Metadata.Content
Assembly: package-graph-microsoft-update.dll
Syntax
public class UpdateFile : IContentFile
Constructors
| Improve this Doc View SourceUpdateFile()
Create a new UpdateFile
Declaration
[JsonConstructor]
public UpdateFile()
Properties
| Improve this Doc View SourceDigest
Gets the primary digest of a content file.
Declaration
[JsonIgnore]
public IContentFileDigest Digest { get; }
Property Value
Type | Description |
---|---|
IContentFileDigest | Content file digest. |
Digests
Gets the list of file digests. Multiple hashing algorithms might be used.
Declaration
[JsonProperty]
public List<ContentFileDigest> Digests { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.List<ContentFileDigest> | List of file digests, one per algorithm. |
FileName
Gets the name of the file
Declaration
[JsonProperty]
public string FileName { get; set; }
Property Value
Type | Description |
---|---|
System.String | File name |
ModifiedDate
Gets the last modified timestamp for the file
Declaration
[JsonProperty]
public DateTime ModifiedDate { get; set; }
Property Value
Type | Description |
---|---|
System.DateTime | Last modified DateTime |
PatchingType
Gets the type of patching this file provides
Declaration
[JsonProperty]
public string PatchingType { get; set; }
Property Value
Type | Description |
---|---|
System.String | Patchin type string |
Size
Ges the file size, in bytes.
Declaration
[JsonProperty]
public ulong Size { get; set; }
Property Value
Type | Description |
---|---|
System.UInt64 | File size |
Source
Gets the default download URL for a file.
Declaration
[JsonIgnore]
public string Source { get; }
Property Value
Type | Description |
---|---|
System.String |
Urls
Gets the list of URLs for the file.
Declaration
[JsonProperty]
public List<UpdateFileUrl> Urls { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.List<UpdateFileUrl> | List of URLs. |
Methods
| Improve this Doc View SourceEquals(Object)
Override equality method; two UpdateFile are equal if they have the same content hash.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | Other UpdateFile |
Returns
Type | Description |
---|---|
System.Boolean | True if the two objects are equal, false otherwise |
Overrides
GetHashCode()
Return a hash code based on the hash of the file content.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | UpdateFile hash code |