Exemplo n.º 1
0
 private static void ProcessTweets(ITweetOutbox tweetOutbox, string consumerKey, string consumerSecret, string token, string tokenSecret)
 {
     try
     {
         tweetOutbox.ProcessAll(SendTweet);
     } catch (Exception ex)
     {
         logger.Fatal(ex);
         Environment.Exit(-1);
     }
 }
Exemplo n.º 2
0
 private static void ProcessTweets(ITweetOutbox tweetOutbox, string consumerKey, string consumerSecret, string token, string tokenSecret)
 {
     try
     {
         tweetOutbox.ProcessAll(SendTweet);
     } catch (Exception ex)
     {
         logger.Fatal(ex);
         Environment.Exit(-1);
     }
 }
Exemplo n.º 3
0
        static void Main(string[] args)
        {
            Console.Clear();
            log4net.Config.XmlConfigurator.Configure();
            consumerKey = ConfigurationManager.AppSettings["Twitter_ConsumerKey"];
            consumerSecret = ConfigurationManager.AppSettings["Twitter_ConsumerSecret"];
            token = ConfigurationManager.AppSettings["Twitter_Token"];
            tokenSecret = ConfigurationManager.AppSettings["Twitter_TokenSecret"];
            string directory = ConfigurationManager.AppSettings["TweetOutboxDirectory"];
            tweetOutbox = new TweetOutbox(directory);

            outboxWatcher = new FileSystemWatcher(directory);
            outboxWatcher.EnableRaisingEvents = true;
            outboxWatcher.Changed += new FileSystemEventHandler(fsw_Changed);
            Console.WriteLine("Running - press the return key to exit");
            Console.ReadLine();
        }
Exemplo n.º 4
0
        static void Main(string[] args)
        {
            Console.Clear();
            log4net.Config.XmlConfigurator.Configure();
            consumerKey    = ConfigurationManager.AppSettings["Twitter_ConsumerKey"];
            consumerSecret = ConfigurationManager.AppSettings["Twitter_ConsumerSecret"];
            token          = ConfigurationManager.AppSettings["Twitter_Token"];
            tokenSecret    = ConfigurationManager.AppSettings["Twitter_TokenSecret"];
            string directory = ConfigurationManager.AppSettings["TweetOutboxDirectory"];

            tweetOutbox = new TweetOutbox(directory);

            outboxWatcher = new FileSystemWatcher(directory);
            outboxWatcher.EnableRaisingEvents = true;
            outboxWatcher.Changed            += new FileSystemEventHandler(fsw_Changed);
            Console.WriteLine("Running - press the return key to exit");
            Console.ReadLine();
        }
Exemplo n.º 5
0
 public SdiController(ITweetOutbox tweetOutbox)
 {
     _tweetOutbox = tweetOutbox;
 }
Exemplo n.º 6
0
 public SdiController()
 {
     _tweetOutbox      = new TweetOutbox(ConfigurationManager.AppSettings["TweetOutboxDirectory"]);
     indulgenceEmailer = new EmailProcessIndulgenceEmailer();
 }
Exemplo n.º 7
0
 public SdiController(ITweetOutbox tweetOutbox)
 {
     _tweetOutbox = tweetOutbox;
 }
Exemplo n.º 8
0
 public SdiController()
 {
     _tweetOutbox = new TweetOutbox(ConfigurationManager.AppSettings["TweetOutboxDirectory"]);
     indulgenceEmailer = new EmailProcessIndulgenceEmailer();
 }