Saltar al contenido principal

VelopackAsset class

Namespace: Velopack

An individual Velopack asset, could refer to an asset on-disk or in a remote package feed.

public record VelopackAsset : IEquatable<VelopackAsset>

Implements: IEquatable<VelopackAsset>

Constructors

ConstructorSummary
VelopackAsset
VelopackAsset

VelopackAsset(original)

protected VelopackAsset(VelopackAsset original)

Parameters

NameTypeDescription
originalVelopackAsset

VelopackAsset()

public VelopackAsset()

Properties

PropertySummary
EqualityContract
PackageIdThe name or Id of the package containing this release.
VersionThe version of this release.
TypeThe type of asset (eg. full or delta).
FileNameThe filename of the update package containing this release.
SHA1The SHA1 checksum of the update package containing this release.
SHA256The SHA256 checksum (if available) of the update package containing this release.
SizeThe size in bytes of the update package containing this release.
NotesMarkdownThe release notes in markdown format, as passed to Velopack when packaging the release.
NotesHTMLThe release notes in HTML format, transformed from Markdown when packaging the release.

EqualityContract

protected virtual Type EqualityContract { get; }

PackageId

public string PackageId { get; set; }

The name or Id of the package containing this release.

Version

public SemanticVersion Version { get; set; }

The version of this release.

Type

public VelopackAssetType Type { get; set; }

The type of asset (eg. full or delta).

FileName

public string FileName { get; set; }

The filename of the update package containing this release.

SHA1

public string SHA1 { get; set; }

The SHA1 checksum of the update package containing this release.

SHA256

public string SHA256 { get; set; }

The SHA256 checksum (if available) of the update package containing this release.

Size

public long Size { get; set; }

The size in bytes of the update package containing this release.

NotesMarkdown

public string NotesMarkdown { get; set; }

The release notes in markdown format, as passed to Velopack when packaging the release.

NotesHTML

public string NotesHTML { get; set; }

The release notes in HTML format, transformed from Markdown when packaging the release.

Methods

MethodSummary
FromZipPackageNoChecksumConvert a ZipPackage to a VelopackAsset without computing checksums.
FromZipPackageGenerateChecksumAsyncConvert a ZipPackage to a VelopackAsset, computing SHA1 and SHA256 checksums asynchronously.
FromNupkgNoChecksumLoad a VelopackAsset from a .nupkg file on disk without computing checksums.
FromNupkgGenerateChecksumAsyncLoad a VelopackAsset from a .nupkg file on disk, computing SHA1 and SHA256 checksums asynchronously.
ToString
PrintMembers
GetHashCode
Equals
Equals

FromZipPackageNoChecksum(zip)

public static VelopackAsset FromZipPackageNoChecksum(ZipPackage zip)

Convert a ZipPackage to a VelopackAsset without computing checksums.

Parameters

NameTypeDescription
zipZipPackage

Returns VelopackAsset

FromZipPackageGenerateChecksumAsync(zip)

public static Task<VelopackAsset> FromZipPackageGenerateChecksumAsync(ZipPackage zip)

Convert a ZipPackage to a VelopackAsset, computing SHA1 and SHA256 checksums asynchronously.

Parameters

NameTypeDescription
zipZipPackage

Returns Task<VelopackAsset>

FromNupkgNoChecksum(filePath)

public static VelopackAsset FromNupkgNoChecksum(string filePath)

Load a VelopackAsset from a .nupkg file on disk without computing checksums.

Parameters

NameTypeDescription
filePathstring

Returns VelopackAsset

FromNupkgGenerateChecksumAsync(filePath)

public static Task<VelopackAsset> FromNupkgGenerateChecksumAsync(string filePath)

Load a VelopackAsset from a .nupkg file on disk, computing SHA1 and SHA256 checksums asynchronously.

Parameters

NameTypeDescription
filePathstring

Returns Task<VelopackAsset>

ToString()

public override string ToString()

Returns string

PrintMembers(builder)

protected virtual bool PrintMembers(StringBuilder builder)

Parameters

NameTypeDescription
builderStringBuilder

Returns bool

GetHashCode()

public override int GetHashCode()

Returns int

Equals(obj)

public override bool Equals(object? obj)

Parameters

NameTypeDescription
objobject

Returns bool

Equals(other)

public virtual bool Equals(VelopackAsset? other)

Parameters

NameTypeDescription
otherVelopackAsset

Returns bool

Operators

OperatorSummary
operator !=
operator ==

operator !=(left, right)

public static bool operator !=(VelopackAsset? left, VelopackAsset? right)

Parameters

NameTypeDescription
leftVelopackAsset
rightVelopackAsset

Returns bool

operator ==(left, right)

public static bool operator ==(VelopackAsset? left, VelopackAsset? right)

Parameters

NameTypeDescription
leftVelopackAsset
rightVelopackAsset

Returns bool


Generated from Velopack 1.1.1