38 instantiations of ZipArchive
BuildBoss (1)
OptProfCheckerUtil.cs (1)
103using (var archive = new ZipArchive(File.Open(vsixFullPath, FileMode.Open), ZipArchiveMode.Read))
Microsoft.Arcade.Common (3)
NupkgInfoFactory.cs (1)
32ZipArchive zipArchive = new(stream, ZipArchiveMode.Read);
ZipArchiveManager.cs (2)
33using ZipArchive zip = new(fs, archiveExists ? ZipArchiveMode.Update : ZipArchiveMode.Create, false); 50using ZipArchive archive = new(archiveStream, ZipArchiveMode.Update);
Microsoft.Build (2)
Logging\BinaryLogger\BuildEventArgsReader.cs (1)
408using var zipArchive = new ZipArchive(embeddedStream, ZipArchiveMode.Read);
Logging\BinaryLogger\ProjectImportsCollector.cs (1)
83_zipArchive = new ZipArchive(_fileStream, ZipArchiveMode.Create);
Microsoft.Build.Engine.UnitTests (2)
BinaryLogger_Tests.cs (2)
460using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read); 520using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read);
Microsoft.Build.Tasks.Core (1)
Unzip.cs (1)
120using (ZipArchive zipArchive = new ZipArchive(stream, ZipArchiveMode.Read, leaveOpen: false))
Microsoft.Build.Tasks.UnitTests (4)
CodeTaskFactoryEmbeddedFileInBinlogTestHelper.cs (2)
67using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read); 119using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read);
ZipDirectory_Tests.cs (2)
47using (ZipArchive archive = new ZipArchive(stream, ZipArchiveMode.Read)) 89using (ZipArchive archive = new ZipArchive(stream, ZipArchiveMode.Read))
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
OptProf\GenerateTrainingInputFiles.cs (1)
99using (var archive = new ZipArchive(File.Open(vsixPath, FileMode.Open), ZipArchiveMode.Read))
Microsoft.DotNet.Build.Tasks.VisualStudio.Tests (1)
OptProf\GenerateTrainingInputFilesTests.cs (1)
122using (var archive = new ZipArchive(fileStream, ZipArchiveMode.Create))
Microsoft.DotNet.Helix.JobSender (3)
Payloads\AdhocPayload.cs (1)
34using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Payloads\DirectoryPayload.cs (1)
56using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Payloads\SingleFilePayload.cs (1)
38using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Microsoft.DotNet.NuGetRepack.Tasks (1)
src\ReplacePackageParts.cs (1)
232using (var archive = new ZipArchive(File.Open(tempPackagePath, FileMode.Open, FileAccess.ReadWrite), ZipArchiveMode.Update))
Microsoft.DotNet.NuGetRepack.Tests (2)
ReplacePackagePartsTests.cs (1)
43using (var archive = new ZipArchive(File.Open(task.NewPackage, FileMode.Open, FileAccess.Read), ZipArchiveMode.Read))
VersionUpdaterTests.cs (1)
23using (var package = new ZipArchive(new MemoryStream(packageBytes), ZipArchiveMode.Read))
Microsoft.DotNet.SignCheckLibrary (1)
Verification\ZipVerifier.cs (1)
23using (var archive = new ZipArchive(File.OpenRead(archivePath), ZipArchiveMode.Read, leaveOpen: false))
Microsoft.DotNet.SignTool (3)
src\VerifySignatures.cs (1)
172using var archive = new ZipArchive(File.OpenRead(filePath), ZipArchiveMode.Read, leaveOpen: false);
src\ZipData.cs (2)
195using (var archive = new ZipArchive(File.OpenRead(archivePath), ZipArchiveMode.Read, leaveOpen: false)) 222using (var archive = new ZipArchive(zipStream, ZipArchiveMode.Update))
Microsoft.DotNet.SourceBuild.Tasks (1)
src\UsageReport\WritePackageUsageData.cs (1)
152using (var projectAssetArchive = new ZipArchive(
Microsoft.ML.Core (2)
Data\Repository.cs (2)
306_archive = new ZipArchive(stream, ZipArchiveMode.Create, leaveOpen: true); 462_archive = new ZipArchive(stream, ZipArchiveMode.Read, true);
Microsoft.ML.Ensemble (2)
EntryPoints\CreateEnsemble.cs (2)
333var zip = new ZipArchive(ms); 381var zip = new ZipArchive(ms);
System.IO.Compression (3)
System\IO\Compression\ZipArchive.Async.cs (1)
85ZipArchive zipArchive = new(mode, leaveOpen, entryNameEncoding, backingStream, DecideArchiveStream(mode, stream));
System\IO\Compression\ZipArchive.cs (1)
205/// The comment encoding is determined by the <c>entryNameEncoding</c> parameter of the <see cref="ZipArchive(Stream,ZipArchiveMode,bool,Encoding?)"/> constructor.
System\IO\Compression\ZipArchiveEntry.cs (1)
208///The comment encoding is determined by the <c>entryNameEncoding</c> parameter of the <see cref="ZipArchive(Stream,ZipArchiveMode,bool,Encoding?)"/> constructor.
System.IO.Compression.ZipFile (3)
System\IO\Compression\ZipFile.Create.cs (2)
155return new ZipArchive(fs, mode, leaveOpen: false, entryNameEncoding: entryNameEncoding); 422using ZipArchive archive = new ZipArchive(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding);
System\IO\Compression\ZipFile.Extract.cs (1)
328using ZipArchive archive = new ZipArchive(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding);
System.IO.Packaging (2)
System\IO\Packaging\ZipPackage.cs (2)
328zipArchive = new ZipArchive(_containerStream, zipArchiveMode, true); 398zipArchive = new ZipArchive(s, zipArchiveMode, true);
118 references to ZipArchive
BuildBoss (1)
OptProfCheckerUtil.cs (1)
103using (var archive = new ZipArchive(File.Open(vsixFullPath, FileMode.Open), ZipArchiveMode.Read))
Microsoft.Arcade.Common (5)
IZipArchiveManager.cs (1)
17ZipArchive OpenArchive(string archivePath, ZipArchiveMode mode);
NupkgInfoFactory.cs (1)
32ZipArchive zipArchive = new(stream, ZipArchiveMode.Read);
ZipArchiveManager.cs (3)
15public ZipArchive OpenArchive(string archivePath, ZipArchiveMode mode) 33using ZipArchive zip = new(fs, archiveExists ? ZipArchiveMode.Update : ZipArchiveMode.Create, false); 50using ZipArchive archive = new(archiveStream, ZipArchiveMode.Update);
Microsoft.AspNetCore.App.UnitTests (2)
SharedFxTests.cs (1)
330ZipArchive archive = ZipFile.OpenRead(sharedFxPath);
TargetingPackTests.cs (1)
373ZipArchive archive = ZipFile.OpenRead(targetingPackPath);
Microsoft.Build (2)
Logging\BinaryLogger\BuildEventArgsReader.cs (1)
408using var zipArchive = new ZipArchive(embeddedStream, ZipArchiveMode.Read);
Logging\BinaryLogger\ProjectImportsCollector.cs (1)
26private ZipArchive? _zipArchive;
Microsoft.Build.CommandLine.UnitTests (1)
XMake_Tests.cs (1)
2543using ZipArchive archive = ZipFile.OpenRead($"{binLogLocation}/replay.ProjectImports.zip");
Microsoft.Build.Engine.UnitTests (2)
BinaryLogger_Tests.cs (2)
460using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read); 520using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read);
Microsoft.Build.Tasks.Core (3)
Unzip.cs (3)
120using (ZipArchive zipArchive = new ZipArchive(stream, ZipArchiveMode.Read, leaveOpen: false)) 159/// <param name="sourceArchive">The <see cref="ZipArchive"/> containing the files to extract.</param> 161private void Extract(ZipArchive sourceArchive, DirectoryInfo destinationDirectory)
Microsoft.Build.Tasks.UnitTests (4)
CodeTaskFactoryEmbeddedFileInBinlogTestHelper.cs (2)
67using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read); 119using var zipArchive = new ZipArchive(fileStream, ZipArchiveMode.Read);
ZipDirectory_Tests.cs (2)
47using (ZipArchive archive = new ZipArchive(stream, ZipArchiveMode.Read)) 89using (ZipArchive archive = new ZipArchive(stream, ZipArchiveMode.Read))
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
OptProf\GenerateTrainingInputFiles.cs (1)
99using (var archive = new ZipArchive(File.Open(vsixPath, FileMode.Open), ZipArchiveMode.Read))
Microsoft.DotNet.Build.Tasks.VisualStudio.Tests (1)
OptProf\GenerateTrainingInputFilesTests.cs (1)
122using (var archive = new ZipArchive(fileStream, ZipArchiveMode.Create))
Microsoft.DotNet.Helix.JobSender (3)
Payloads\AdhocPayload.cs (1)
34using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Payloads\DirectoryPayload.cs (1)
56using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Payloads\SingleFilePayload.cs (1)
38using (var zip = new ZipArchive(stream, ZipArchiveMode.Create, true))
Microsoft.DotNet.Helix.Sdk (1)
ProvisioningProfileProvider.cs (1)
124using ZipArchive zipArchive = _zipArchiveManager.OpenArchive(archivePath, ZipArchiveMode.Update);
Microsoft.DotNet.Internal.SymbolHelper (2)
SymbolUploadHelper.cs (1)
273using ZipArchive archive = ZipFile.Open(packagePath, ZipArchiveMode.Read);
SymbolUploadHelperFactory.cs (1)
139using ZipArchive archive = ZipFile.OpenRead(toolZipPath);
Microsoft.DotNet.NuGetRepack.Tasks (1)
src\ReplacePackageParts.cs (1)
232using (var archive = new ZipArchive(File.Open(tempPackagePath, FileMode.Open, FileAccess.ReadWrite), ZipArchiveMode.Update))
Microsoft.DotNet.NuGetRepack.Tests (2)
ReplacePackagePartsTests.cs (1)
43using (var archive = new ZipArchive(File.Open(task.NewPackage, FileMode.Open, FileAccess.Read), ZipArchiveMode.Read))
VersionUpdaterTests.cs (1)
23using (var package = new ZipArchive(new MemoryStream(packageBytes), ZipArchiveMode.Read))
Microsoft.DotNet.SignCheckLibrary (5)
Verification\Jar\JarManifestFile.cs (1)
41using (ZipArchive archive = ZipFile.Open(ArchivePath, ZipArchiveMode.Read))
Verification\Jar\JarManifestFileBase.cs (1)
93using (ZipArchive archive = ZipFile.Open(ArchivePath, ZipArchiveMode.Read))
Verification\Jar\JarUtils.cs (1)
25using (ZipArchive archive = ZipFile.Open(archivePath, ZipArchiveMode.Read))
Verification\SignatureVerificationManager.cs (1)
246using (ZipArchive zipArchive = ZipFile.OpenRead(path))
Verification\ZipVerifier.cs (1)
23using (var archive = new ZipArchive(File.OpenRead(archivePath), ZipArchiveMode.Read, leaveOpen: false))
Microsoft.DotNet.SignTool (4)
src\SignTool.cs (1)
94using (var archive = ZipFile.Open(zipFilePath, ZipArchiveMode.Create))
src\VerifySignatures.cs (1)
172using var archive = new ZipArchive(File.OpenRead(filePath), ZipArchiveMode.Read, leaveOpen: false);
src\ZipData.cs (2)
195using (var archive = new ZipArchive(File.OpenRead(archivePath), ZipArchiveMode.Read, leaveOpen: false)) 222using (var archive = new ZipArchive(zipStream, ZipArchiveMode.Update))
Microsoft.DotNet.SourceBuild.Tasks (1)
src\UsageReport\WritePackageUsageData.cs (1)
152using (var projectAssetArchive = new ZipArchive(
Microsoft.ML.Core (4)
ComponentModel\AssemblyLoadingUtils.cs (1)
48ZipArchive zip;
Data\Repository.cs (3)
40/// Abstraction around a <see cref="ZipArchive"/> or other hierarchical storage. 288private ZipArchive _archive; 444private readonly ZipArchive _archive;
Microsoft.ML.Ensemble (4)
EntryPoints\CreateEnsemble.cs (4)
315/// This method takes a <see cref="RoleMappedData"/> as input, saves it as an in-memory <see cref="ZipArchive"/> 333var zip = new ZipArchive(ms); 353/// The comparison is done by saving <see ref="dataToCompare"/> as an in-memory <see cref="ZipArchive"/>, 381var zip = new ZipArchive(ms);
Microsoft.ML.IntegrationTests (1)
ModelFiles.cs (1)
61using (ZipArchive archive = ZipFile.OpenRead(modelPath))
Microsoft.ML.TestFramework (1)
DataPipe\TestDataPipe.cs (1)
1058using (var zip = new ZipArchive(strm, ZipArchiveMode.Read))
netstandard (1)
netstandard.cs (1)
895[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.IO.Compression.ZipArchive))]
System.IO.Compression (21)
System\IO\Compression\ZipArchive.Async.cs (3)
15/// 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. 65public static async Task<ZipArchive> CreateAsync(Stream stream, ZipArchiveMode mode, bool leaveOpen, Encoding? entryNameEncoding, CancellationToken cancellationToken = default) 85ZipArchive zipArchive = new(mode, leaveOpen, entryNameEncoding, backingStream, DecideArchiveStream(mode, stream));
System\IO\Compression\ZipArchiveEntry.Async.cs (1)
215Changes |= ZipArchive.ChangeState.StoredData;
System\IO\Compression\ZipArchiveEntry.cs (17)
19private ZipArchive _archive; 52internal ZipArchiveEntry(ZipArchive archive, ZipCentralDirectoryFileHeader cd) 61Changes = ZipArchive.ChangeState.Unchanged; 101internal ZipArchiveEntry(ZipArchive archive, string entryName, CompressionLevel compressionLevel) 113internal ZipArchiveEntry(ZipArchive archive, string entryName) 160Changes = ZipArchive.ChangeState.Unchanged; 166public ZipArchive Archive => _archive; 200Changes |= ZipArchive.ChangeState.FixedLengthMetadata; 223Changes |= ZipArchive.ChangeState.DynamicLengthMetadata; 288Changes |= ZipArchive.ChangeState.FixedLengthMetadata; 311internal ZipArchive.ChangeState Changes { get; private set; } 556if (_originallyInArchive && Changes == ZipArchive.ChangeState.Unchanged && !forceWrite) 790Changes |= ZipArchive.ChangeState.StoredData; 811Changes |= ZipArchive.ChangeState.StoredData; 1044if (_originallyInArchive && Changes == ZipArchive.ChangeState.Unchanged && !forceWrite) 1341Changes |= ZipArchive.ChangeState.FixedLengthMetadata; 1346Changes |= ZipArchive.ChangeState.FixedLengthMetadata;
System.IO.Compression.ZipFile (31)
System\IO\Compression\ZipFile.Create.Async.cs (8)
35public static Task<ZipArchive> OpenReadAsync(string archiveFileName, CancellationToken cancellationToken = default) => OpenAsync(archiveFileName, ZipArchiveMode.Read, cancellationToken); 74public static Task<ZipArchive> OpenAsync(string archiveFileName, ZipArchiveMode mode, CancellationToken cancellationToken = default) => OpenAsync(archiveFileName, mode, entryNameEncoding: null, cancellationToken); 152public static async Task<ZipArchive> OpenAsync(string archiveFileName, ZipArchiveMode mode, Encoding? entryNameEncoding, CancellationToken cancellationToken = default) 165return await ZipArchive.CreateAsync(fs, mode, leaveOpen: false, entryNameEncoding: entryNameEncoding, cancellationToken).ConfigureAwait(false); 437ZipArchive archive = await OpenAsync(destinationArchiveFileName, ZipArchiveMode.Create, entryNameEncoding, cancellationToken).ConfigureAwait(false); 451ZipArchive archive = await ZipArchive.CreateAsync(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false); 458private static async Task CreateZipArchiveFromDirectoryAsync(string sourceDirectoryName, ZipArchive archive,
System\IO\Compression\ZipFile.Create.cs (7)
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) 413using ZipArchive archive = Open(destinationArchiveFileName, ZipArchiveMode.Create, entryNameEncoding); 422using ZipArchive archive = new ZipArchive(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding); 426private static void CreateZipArchiveFromDirectory(string sourceDirectoryName, ZipArchive archive, 525private static void FinalizeCreateZipArchiveFromDirectory(ZipArchive archive, DirectoryInfo di, bool includeBaseDirectory, bool directoryIsEmpty)
System\IO\Compression\ZipFile.Extract.Async.cs (3)
197ZipArchive archive = await OpenAsync(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding, cancellationToken).ConfigureAwait(false); 351ZipArchive archive = await ZipArchive.CreateAsync(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false);
System\IO\Compression\ZipFile.Extract.cs (2)
185using (ZipArchive archive = Open(sourceArchiveFileName, ZipArchiveMode.Read, entryNameEncoding)) 328using ZipArchive archive = new ZipArchive(source, ZipArchiveMode.Read, leaveOpen: true, entryNameEncoding);
System\IO\Compression\ZipFileExtensions.ZipArchive.Create.Async.cs (3)
46public static Task<ZipArchiveEntry> CreateEntryFromFileAsync(this ZipArchive destination, string sourceFileName, string entryName, CancellationToken cancellationToken = default) => 79public static Task<ZipArchiveEntry> CreateEntryFromFileAsync(this ZipArchive destination, 83internal static async Task<ZipArchiveEntry> DoCreateEntryFromFileAsync(this ZipArchive destination, string sourceFileName, string entryName,
System\IO\Compression\ZipFileExtensions.ZipArchive.Create.cs (4)
44public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination, string sourceFileName, string entryName) => 76public static ZipArchiveEntry CreateEntryFromFile(this ZipArchive destination, 80internal static ZipArchiveEntry DoCreateEntryFromFile(this ZipArchive destination, 96private static (FileStream, ZipArchiveEntry) InitializeDoCreateEntryFromFile(ZipArchive destination, string sourceFileName, string entryName, CompressionLevel? compressionLevel, bool useAsync)
System\IO\Compression\ZipFileExtensions.ZipArchive.Extract.Async.cs (2)
39public static Task ExtractToDirectoryAsync(this ZipArchive source, string destinationDirectoryName, CancellationToken cancellationToken = default) => 71public static async Task ExtractToDirectoryAsync(this ZipArchive source, string destinationDirectoryName, bool overwriteFiles, CancellationToken cancellationToken = default)
System\IO\Compression\ZipFileExtensions.ZipArchive.Extract.cs (2)
35public static void ExtractToDirectory(this ZipArchive source, string destinationDirectoryName) => 66public static void ExtractToDirectory(this ZipArchive source, string destinationDirectoryName, bool overwriteFiles)
System.IO.Packaging (14)
System\IO\Packaging\InterleavedZipPackagePartStream.PieceDirectory.cs (1)
52private readonly ZipArchive _zipArchive;
System\IO\Packaging\ZipPackage.cs (7)
310ZipArchive? zipArchive = null; 355ZipArchive? zipArchive = null; 705private readonly ZipArchive _zipArchive; 768internal ContentTypeHelper(ZipArchive zipArchive, FileMode packageFileMode, FileAccess packageFileAccess, ZipStreamManager zipStreamManager, IgnoredItemHelper ignoredItemHelper) 1295private readonly ZipArchive _zipArchive; 1361private readonly ZipArchive _zipArchive; 1368internal IgnoredItemHelper(ZipArchive zipArchive)
System\IO\Packaging\ZipPackagePart.cs (3)
61ZipArchive zipArchive, 81ZipArchive zipArchive, 115private readonly ZipArchive _zipArchive;
System\IO\Packaging\ZipPackagePartPiece.cs (1)
143internal static ZipPackagePartPiece Create(ZipArchive zipArchive, PackUriHelper.ValidatedPartUri? partUri, string prefixName, int pieceNumber, bool isLastPiece)
System\IO\Packaging\ZipStreamManager.cs (2)
14private readonly ZipArchive _zipArchive; 18public ZipStreamManager(ZipArchive zipArchive, FileMode packageFileMode, FileAccess packageFileAccess)