Example #1
0
        private async Task LoadAndSaveRoomConfig(string recorderRoomConfigId, string jsonFileName)
        {
            var result = await HttpHandlers.ExportRoomCfg(recorderRoomConfigId, this);

            if (result == null)
            {
                return;
            }

            using (var textWriter =
                       new StreamWriter(new FileStream(jsonFileName, FileMode.Create, FileAccess.ReadWrite), Encoding.Default))
            {
                textWriter.Write(Encoding.UTF8.GetString(result));
            }
        }