コード例 #1
0
        public void WinToTrelloTest()
        {
            _source = new WindowsFileRepository(@"D:\CodeProject\SyncFile\temp1");

            _destination = new TrelloFileRepository(
                ConfigurationManager.AppSettings["key"],
                ConfigurationManager.AppSettings["token"],
                ConfigurationManager.AppSettings["list"]
                );

            ISyncBusiness isyncbusiness = new SyncBusiness(_source, _destination);

            isyncbusiness.Sync();
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: jonmu0922/SyncFile
        static IFileRepository FileRepositoryFactory(NameValueCollection nvc)
        {
            IFileRepository result = null;

            switch (nvc["Type"])
            {
            case "WindowsFileRepository":
                result = new WindowsFileRepository(nvc["BasePath"]);
                break;

            case "TrelloFileRepository":
                result = new TrelloFileRepository(nvc["Key"], nvc["Token"], nvc["List"]);
                break;
            }

            return(result);
        }