Table of Contents

Class S100FeedPackager

Namespace
EncDotNet.S100.Collections.Feeds
Assembly
EncDotNet.S100.Collections.dll

Writes a published item's download (issue #680): a zip holding its exchange-set catalogue, base file and updates at their paths relative to the item's root, whether that root is a folder or a ZIP archive.

public static class S100FeedPackager
Inheritance
S100FeedPackager
Inherited Members

Methods

EstimateSize(LocalItemLocation)

The total (uncompressed) size of the item's files, or null when unknown.

public static long? EstimateSize(LocalItemLocation location)

Parameters

location LocalItemLocation

Returns

long?

Exists(LocalItemLocation)

True when the item's base file is present, so it can be published.

public static bool Exists(LocalItemLocation location)

Parameters

location LocalItemLocation

Returns

bool

Files(LocalItemLocation)

The files of location, relative to its root: catalogue first, then base, then updates.

public static IReadOnlyList<string> Files(LocalItemLocation location)

Parameters

location LocalItemLocation

Returns

IReadOnlyList<string>

LastModified(LocalItemLocation)

When the item's files last changed (the latest of them), or null when unknown.

public static DateTimeOffset? LastModified(LocalItemLocation location)

Parameters

location LocalItemLocation

Returns

DateTimeOffset?

Stamp(LocalItemLocation)

A token that changes whenever the item's download would change: its files' paths, sizes and modification times. Exporters compare it to skip rewriting unchanged downloads.

public static string Stamp(LocalItemLocation location)

Parameters

location LocalItemLocation

Returns

string

WriteZipAsync(Stream, LocalItemLocation, CancellationToken)

Writes the zip for location to output (which need not seek).

public static Task WriteZipAsync(Stream output, LocalItemLocation location, CancellationToken cancellationToken = default)

Parameters

output Stream
location LocalItemLocation
cancellationToken CancellationToken

Returns

Task

Exceptions

FileNotFoundException

The base file is gone.