Exemple #1
0
 public async void SaveAsync(long telegramChatId, ScheduleSession session)
 {
     await dbClient
     .Child(sessionsKey)
     .Child(telegramChatId.ToString())
     .PutAsync(session);
 }
Exemple #2
0
        public void Save(long telegramChatId, ScheduleSession session)
        {
            Console.WriteLine("<Saving>");
            var savingTask = dbClient
                             .Child(sessionsKey)
                             .Child(telegramChatId.ToString())
                             .PutAsync(session);

            Console.WriteLine("Waiting Task ...");
            savingTask.Wait();
            Console.WriteLine("Saved on {0}/{1}", sessionsKey, telegramChatId);
        }