Example #1
0
 public static bool ValidateFileHandle(this AwsS3FileHandle handle, string data, TimeSpan?ttl)
 {
     using (var reader = new StreamReader(handle.Stream)) {
         var read = reader.ReadToEnd();
         if (data != read)
         {
             _log.DebugFormat("'{0}' != '{1}'", data, read);
             return(false);
         }
     }
     if (ttl != handle.TimeToLive)
     {
         _log.DebugFormat("'{0}' != '{1}'", ttl, handle.TimeToLive);
         return(false);
     }
     return(true);
 }
Example #2
0
 public void PutFile(string path, AwsS3FileHandle fileInfo)
 {
     Client.PutFile(path, fileInfo);
 }