52 instantiations of ZipArchive
aspire (2)
Aspire.Dashboard (3)
Aspire.Dashboard.Tests (6)
ILCompiler.ReadyToRun (1)
ILCompiler.RyuJit (1)
Microsoft.Arcade.Common (3)
Microsoft.Build (2)
Microsoft.Build.Tasks.Core (1)
Microsoft.DotNet.ApiSymbolExtensions (1)
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
Microsoft.DotNet.NuGetRepack.Tasks (1)
Microsoft.DotNet.SourceBuild.Tasks (1)
Microsoft.ML.Core (2)
Microsoft.ML.Ensemble (2)
Microsoft.ML.TestFramework (1)
Microsoft.TemplateEngine.Edge (2)
NuGet.PackageManagement (2)
NuGet.Packaging (8)
PackageArchiveReader.cs (5)
82: this(new ZipArchive(stream, ZipArchiveMode.Read, leaveStreamOpen), DefaultFrameworkNameProvider.Instance, DefaultCompatibilityProvider.Instance)
95: this(new ZipArchive(stream, ZipArchiveMode.Read, leaveStreamOpen), frameworkProvider, compatibilityProvider)
139_zipArchive = new ZipArchive(stream, ZipArchiveMode.Read);
414using (var zip = new ZipArchive(ZipReadStream, ZipArchiveMode.Read, leaveOpen: true))
555using (var zip = new ZipArchive(ZipReadStream, ZipArchiveMode.Read, leaveOpen: true))
sdk-tasks (2)
System.IO.Compression (3)
System.IO.Compression.ZipFile (5)
System.IO.Packaging (2)
169 references to ZipArchive
aspire (4)
Aspire.Cli.Tests (8)
Aspire.Dashboard (4)
Aspire.Dashboard.Tests (6)
crossgen2 (1)
ilc (1)
ILCompiler.ReadyToRun (1)
ILCompiler.RyuJit (1)
Microsoft.Arcade.Common (5)
Microsoft.Build (2)
Microsoft.Build.Tasks.Core (3)
Microsoft.DotNet.ApiSymbolExtensions (1)
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
Microsoft.DotNet.NuGetRepack.Tasks (1)
Microsoft.DotNet.SourceBuild.Tasks (1)
Microsoft.ML.Core (4)
Microsoft.ML.Ensemble (4)
Microsoft.ML.IntegrationTests (1)
Microsoft.ML.TestFramework (1)
Microsoft.TemplateEngine.Edge (3)
netstandard (1)
NuGet.Common (1)
NuGet.PackageManagement (3)
NuGet.Packaging (18)
PackageCreation\Authoring\PackageBuilder.cs (9)
344using (var package = new ZipArchive(stream, ZipArchiveMode.Create, leaveOpen: true))
892private ZipArchiveEntry CreateEntry(ZipArchive package, string entryName, CompressionLevel compressionLevel)
902private static ZipArchiveEntry CreatePackageFileEntry(ZipArchive package, string entryName, DateTimeOffset timeOffset, CompressionLevel compressionLevel, StringBuilder warningMessage)
924private void WriteManifest(ZipArchive package, int minimumManifestVersion, string psmdcpPath)
939private SortedSet<string> WriteFiles(ZipArchive package, SortedSet<string> filesWithoutExtensions)
1107private void CreatePart(ZipArchive package, string path, Stream sourceStream, DateTimeOffset lastWriteTime, StringBuilder warningMessage)
1156private void WriteOpcManifestRelationship(ZipArchive package, string path, string psmdcpPath)
1182private void WriteOpcContentTypes(ZipArchive package, SortedSet<string> extensions, SortedSet<string> filesWithoutExtensions)
1225private void WriteOpcPackageProperties(ZipArchive package, string psmdcpPath)
sdk-tasks (2)
System.IO.Compression (26)
System\IO\Compression\ZipArchive.Async.cs (5)
16/// Asynchronously initializes and returns a new instance of <see cref="ZipArchive"/> on the given stream in the specified mode, specifying whether to leave the stream open, with an optional encoding and an optional cancellation token.
66/// <returns>A task that represents the asynchronous initialization. The task result is a <see cref="ZipArchive"/> instance opened on the provided stream.</returns>
67public static async Task<ZipArchive> CreateAsync(Stream stream, ZipArchiveMode mode, bool leaveOpen, Encoding? entryNameEncoding, CancellationToken cancellationToken = default)
87ZipArchive zipArchive = new(mode, leaveOpen, entryNameEncoding, backingStream, DecideArchiveStream(mode, stream));
135/// Asynchronously releases the resources used by the <see cref="ZipArchive"/>.
System.IO.Compression.ZipFile (51)
System\IO\Compression\ZipFile.Create.Async.cs (14)
35/// <returns>A task that represents the asynchronous operation. The task result is an opened <see cref="ZipArchive"/> in <see cref="ZipArchiveMode.Read"/> mode.</returns>
36public static Task<ZipArchive> OpenReadAsync(string archiveFileName, CancellationToken cancellationToken = default) => OpenAsync(archiveFileName, ZipArchiveMode.Read, cancellationToken);
75/// <returns>A task that represents the asynchronous operation. The task result is an opened <see cref="ZipArchive"/> in the requested <paramref name="mode"/>.</returns>
76public static Task<ZipArchive> OpenAsync(string archiveFileName, ZipArchiveMode mode, CancellationToken cancellationToken = default) => OpenAsync(archiveFileName, mode, entryNameEncoding: null, cancellationToken);
154/// <returns>A task that represents the asynchronous operation. The task result is an opened <see cref="ZipArchive"/> in the requested <paramref name="mode"/>.</returns>
155public static async Task<ZipArchive> OpenAsync(string archiveFileName, ZipArchiveMode mode, Encoding? entryNameEncoding, CancellationToken cancellationToken = default)
168return await ZipArchive.CreateAsync(fs, mode, leaveOpen: false, entryNameEncoding: entryNameEncoding, cancellationToken).ConfigureAwait(false);
453ZipArchive archive = await OpenAsync(destinationArchiveFileName, ZipArchiveMode.Create, options.EntryNameEncoding, cancellationToken).ConfigureAwait(false);
480ZipArchive archive = await ZipArchive.CreateAsync(destination, ZipArchiveMode.Create, leaveOpen: true, options.EntryNameEncoding, cancellationToken).ConfigureAwait(false);
499ZipArchive archive = await OpenAsync(destinationArchiveFileName, ZipArchiveMode.Create, entryNameEncoding, cancellationToken).ConfigureAwait(false);
513ZipArchive archive = await ZipArchive.CreateAsync(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false);
520private static async Task CreateZipArchiveFromDirectoryAsync(string sourceDirectoryName, ZipArchive archive,
System\IO\Compression\ZipFile.Create.cs (9)
31public static ZipArchive OpenRead(string archiveFileName) => Open(archiveFileName, ZipArchiveMode.Read);
68public static ZipArchive Open(string archiveFileName, ZipArchiveMode mode) => Open(archiveFileName, mode, entryNameEncoding: null);
144public static ZipArchive Open(string archiveFileName, ZipArchiveMode mode, Encoding? entryNameEncoding)
421using ZipArchive archive = Open(destinationArchiveFileName, ZipArchiveMode.Create, options.EntryNameEncoding);
443using ZipArchive archive = new ZipArchive(destination, ZipArchiveMode.Create, leaveOpen: true, options.EntryNameEncoding);
457using ZipArchive archive = Open(destinationArchiveFileName, ZipArchiveMode.Create, entryNameEncoding);
466using ZipArchive archive = new ZipArchive(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding);
470private static void CreateZipArchiveFromDirectory(string sourceDirectoryName, ZipArchive archive,
572private static void FinalizeCreateZipArchiveFromDirectory(ZipArchive archive, DirectoryInfo di, bool includeBaseDirectory, bool directoryIsEmpty)
System\IO\Compression\ZipFile.Extract.Async.cs (6)
201ZipArchive archive = await OpenAsync(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding, cancellationToken).ConfigureAwait(false);
270ZipArchive archive = await OpenAsync(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding, cancellationToken).ConfigureAwait(false);
432ZipArchive archive = await ZipArchive.CreateAsync(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false);
488ZipArchive archive = await ZipArchive.CreateAsync(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false);
System\IO\Compression\ZipFile.Extract.cs (4)
185using (ZipArchive archive = Open(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding))
248using ZipArchive archive = Open(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding);
392using ZipArchive archive = new ZipArchive(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding);
440using ZipArchive archive = new ZipArchive(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding);
System\IO\Compression\ZipFileExtensions.ZipArchive.Create.cs (6)
44public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination, string sourceFileName, string entryName) =>
76public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination,
91public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination, string sourceFileName, string entryName, ReadOnlySpan<char> password, ZipEncryptionMethod encryption) =>
124public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination,
129internal static ZipArchiveEntry DoCreateEntryFromFile(this ZipArchive destination,
147private static (FileStream, ZipArchiveEntry) InitializeDoCreateEntryFromFile(ZipArchive destination, string sourceFileName, string entryName, CompressionLevel? compressionLevel, bool useAsync, ReadOnlySpan<char> password = default, ZipEncryptionMethod encryption = ZipEncryptionMethod.None)
System.IO.Packaging (14)