Пример #1
0
 /// <summary>
 /// Perform cleanup/finalization steps on StreamPath
 /// </summary>
 /// <remarks>
 /// MemoryStream previously created by GetWriteStream should now be populated with data from source file, and
 /// can now be used to stream attachment to SMTP server
 /// </remarks>
 public override async Task FinalizeWrite(StreamPath streampath)
 {
     streampath.stream.Position = 0;             // Rewind MemoryStream to start of data
     await smtp.SendEmail(messageSubject : streampath.path,
                          messageBody : "Your file is attached",
                          messageTo : config.location,
                          attachment : streampath.stream,
                          attachmentName : streampath.path);
 }
Пример #2
0
 /// <summary>
 /// Perform cleanup/finalization steps on StreamPath (not required)
 /// </summary>
 public override async Task FinalizeWrite(StreamPath streampath)
 {
 }
Пример #3
0
 public abstract Task FinalizeWrite(StreamPath streampath);