static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); foreach(var d in new Devices(ChannelEditing.object_store)) { Device device = d as Device; Console.WriteLine("Device id: {0}\n\tname: {1}\n\ttype: {2}\n\tuids: {3}", device.Id, device.Name, device.DeviceType, string.Join(",", device.UIds)); } // FindUnencryptedQAMChannels(); SDTokenManager token_manager = LoginForm.LoginAndGetTokenManager(); StatusResponse status = new SDStatusReader(token_manager).GetSchedulesDirectStatus(); JSONClient.DisplayJSON(status); if (!status.IsOnline()) { MessageBox.Show("SchedulesDirect JSON API is currently offline. Try again later."); Application.Exit(); } /* var schedule_responses = SDSchedules.GetStationScheduleResponses(new List<string>{ "58623", "62420" }); HashSet<string> programIDs = new HashSet<string>(); foreach(var schedule_response in schedule_responses) { if (schedule_response.programs != null) foreach(var program in schedule_response.programs) programIDs.Add(program.programID); } List<SDProgram> programs = SDProgramFetcher.FetchPrograms(programIDs); */ // SDAccountManagement.AddLineupToAccount("USA-NY67791-QAM"); ProviderCreator.ListProviders(); Application.Run(new ConfigForm(token_manager, status)); }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); foreach (var d in new Devices(ChannelEditing.object_store)) { Device device = d as Device; Console.WriteLine("Device id: {0}\n\tname: {1}\n\ttype: {2}\n\tuids: {3}", device.Id, device.Name, device.DeviceType, string.Join(",", device.UIds)); } // FindUnencryptedQAMChannels(); SDTokenManager token_manager = LoginForm.LoginAndGetTokenManager(); StatusResponse status = new SDStatusReader(token_manager).GetSchedulesDirectStatus(); JSONClient.DisplayJSON(status); if (!status.IsOnline()) { MessageBox.Show("SchedulesDirect JSON API is currently offline. Try again later."); Application.Exit(); } /* var schedule_responses = SDSchedules.GetStationScheduleResponses(new List<string>{ * "58623", "62420" }); * HashSet<string> programIDs = new HashSet<string>(); * foreach(var schedule_response in schedule_responses) * { * if (schedule_response.programs != null) * foreach(var program in schedule_response.programs) * programIDs.Add(program.programID); * } * List<SDProgram> programs = SDProgramFetcher.FetchPrograms(programIDs); */ // SDAccountManagement.AddLineupToAccount("USA-NY67791-QAM"); ProviderCreator.ListProviders(); Application.Run(new ConfigForm(token_manager, status)); }