public async Task WriteAsync(VersionData versionData)
        {
            await writer.WriteLineAsync(versionData.Version.ToString());

            await writer.WriteLineAsync(versionData.Channel);

            await writer.WriteLineAsync(versionData.ManifestPath.ToString());
        }
Exemple #2
0
        private async Task <string> GenerateVersionData(Manifest manifest, Uri manifestEntryUri)
        {
            var versionData = new VersionData(manifest.Version, manifest.Channel, manifestEntryUri);

            var path = Path.GetTempFileName();

            using (var stream = File.OpenWrite(path))
                using (var writer = new VersionDataWriter(stream))
                {
                    await writer.WriteAsync(versionData);

                    await writer.FlushAsync();
                }
            return(path);
        }