public override Task <IPackage> ReadFormDataFromStreamAsync(HashingMultipartFileStreamProvider streamProvider) { IFastZipPackage package = null; try { var packageStream = streamProvider.ContentStreams.Single(); package = repository.LoadStagedPackage(packageStream); } finally { if (package == null) { foreach (var stream in streamProvider.ContentStreams) { repository.DiscardStagedPackage(stream); } } } return(Task.FromResult <IPackage>(package)); }
internal FastZipPackageFile(IFastZipPackage fastZipPackage, string path) { this._fastZipPackage = fastZipPackage; Path = Normalize(path); }
public PackageDisposingStream(IFastZipPackage package, Stream stream) : base(stream) { this.package = package; }
public PackageDisposingStream(IFastZipPackage package, Stream stream) : base(stream) { this.package = package; }
internal FastZipPackageFile(IFastZipPackage fastZipPackage, string path) { this.fastZipPackage = fastZipPackage; Path = Normalize(path); }