Statistics
| Branch: | Revision:

root / trunk / Pithos.Core / IStatusNotification.cs @ e5b65606

History | View | Annotate | Download (1.1 kB)

1
using System.Collections.Generic;
2
using System.Diagnostics;
3
using System.IO;
4
using Pithos.Network;
5

    
6
namespace Pithos.Core
7
{
8
    public interface IStatusNotification
9
    {        
10
        void NotifyChange(string status,TraceLevel level=TraceLevel.Info);
11
        void NotifyChangedFile(string filePath);
12
        void NotifyAccount(AccountInfo policy);
13
        void NotifyConflicts(IEnumerable<FileSystemInfo> conflictFiles, string message);
14
        void NotifyForFiles(IEnumerable<FileSystemInfo> files, string message,TraceLevel level);
15
        void Notify(Notification notification);
16
    }
17

    
18
    public class Notification
19
    {
20
        public TraceLevel Level { get; set; }
21
        public string Title { get; set; }
22
        public string Message { get; set; }
23

    
24
        public Notification()
25
        {
26
            Level=TraceLevel.Info;
27
            Title = "";
28
            Message = "";
29
        }
30
    }
31

    
32
    public class Notification<T>:Notification
33
    {
34
        public T Data { get; set; }
35
    }
36

    
37
    public class FilesNotification:Notification<IEnumerable<FileSystemInfo>>
38
    {        
39
    }
40
}