Пример #1
0
        private void connectButton_Click(object sender, EventArgs e)
        {
            bot = new DiscordBot();
            bot.Run(tokenText.Text);

            ST::Timer timer = new ST::Timer(1000 * (60 * 5));

            timer.Elapsed += OnElapsed;
            timer.Enabled  = true;
        }
Пример #2
0
 public WeakReferenceKeyTable()
 {
     m_entries = new ConcurrentDictionary <WeakReferenceKey <TKey>, TValue>();
     m_gc      = new ST::Timer(CollectGarbage, m_entries, 0, 1000);
 }