Exemplo n.º 1
0
 public MessageStore(DirectoryInfo workingDirectory)
 {
     this.WorkingDirectory = workingDirectory;
     this.cache            = new StoreCache();
     this.log       = new StoreLogger();
     this.fileStore = new FileStore(workingDirectory);
 }
Exemplo n.º 2
0
        private static MessageStore CreateMessageStore(ILogger logger)
        {
            var fileStore =
                new FileStore(
                    new DirectoryInfo(
                        Environment.CurrentDirectory));
            var cache    = new StoreCache(fileStore, fileStore);
            var log      = new StoreLogger(logger, cache, cache);
            var msgStore = new MessageStore(
                log,
                log,
                fileStore);

            return(msgStore);
        }
Exemplo n.º 3
0
        public MessageStore(DirectoryInfo workingDirectory)
        {
            if (workingDirectory == null)
            {
                throw new ArgumentNullException("workingDirectory");
            }
            if (!workingDirectory.Exists)
            {
                throw new ArgumentException("Boo", "workingDirectory");
            }

            this.WorkingDirectory = workingDirectory;
            this.cache            = new StoreCache();
            this.log       = new StoreLogger();
            this.fileStore = new FileStore();
        }