internal UploadedFile Remove(UploadedFile obj)
 {
     foreach (UploadedFile file in base.InnerList)
     {
         if (file == obj)
         {
             base.InnerList.Remove(obj);
             return obj;
         }
     }
     return obj;
 }
Example #2
0
 internal UploadedFile Add(UploadedFile obj)
 {
     base.InnerList.Add(obj);
     return(obj);
 }
 public static void CopyFileInfo(IAsyncUploadResult result, UploadedFile file)
 {
     result.ContentLength = file.ContentLength;
     result.ContentType = file.ContentType;
     result.FileName = Path.GetFileName(file.FileName);
 }
 public UploadedFileInfo(UploadedFile file)
 {
     CopyFileInfo(this, file);
 }
 protected void SaveToTempFolder(UploadedFile file, IAsyncUploadConfiguration config, HttpContext context, string tempFileName)
 {
     this.AddCacheDependency(context, tempFileName, config.TimeToLive, this.FullPath);
     file.SaveAs(this.FullPath, false);
 }
 internal UploadedFile Add(UploadedFile obj)
 {
     base.InnerList.Add(obj);
     return obj;
 }
 protected internal virtual IAsyncUploadResult Process(UploadedFile file, HttpContext context, IAsyncUploadConfiguration configuration, string tempFileName)
 {
     this.SaveToTempFolder(file, configuration, context, tempFileName);
     return(this.CreateDefaultUploadResult <UploadedFileInfo>(file));
 }
 public AsyncPostedFile(UploadedFile postedFile, string fullPath, int contentLength, bool chunkRequest)
     : this(postedFile, fullPath, contentLength)
 {
     this._chunkRequest = chunkRequest;
 }
 public AsyncPostedFile(UploadedFile postedFile, string fullPath, int contentLength)
 {
     this.PostedFile = postedFile;
     this.Path = fullPath;
     this.Init(contentLength);
 }
Example #10
0
 public AsyncPostedFile(UploadedFile postedFile, string fullPath, int contentLength, bool chunkRequest)
     : this(postedFile, fullPath, contentLength)
 {
     this._chunkRequest = chunkRequest;
 }
Example #11
0
 public AsyncPostedFile(UploadedFile postedFile, string fullPath, int contentLength)
 {
     this.PostedFile = postedFile;
     this.Path       = fullPath;
     this.Init(contentLength);
 }