当前位置: 首页>>代码示例>>C#>>正文


C# EmptyClass.getfreetime方法代码示例

本文整理汇总了C#中EmptyClass.getfreetime方法的典型用法代码示例。如果您正苦于以下问题:C# EmptyClass.getfreetime方法的具体用法?C# EmptyClass.getfreetime怎么用?C# EmptyClass.getfreetime使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在EmptyClass的用法示例。


在下文中一共展示了EmptyClass.getfreetime方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: initFree

 /// <summary>
 /// 获得各个学号的课表
 /// </summary>
 private async void initFree()
 {
     for (int i = 0; i < muIdList.Count; i++)
     {
         int issuccess = 0;
         List<ClassListLight> clist = new List<ClassListLight>();
         while (issuccess < 2) //失败后重试两次
         {
             List<KeyValuePair<String, String>> paramList = new List<KeyValuePair<String, String>>();
             paramList.Add(new KeyValuePair<string, string>("stuNum", muIdList[i].uId));
             string kbtemp = await NetWork.getHttpWebRequest("redapi2/api/kebiao", paramList); //新
             if (kbtemp != "")
             {
                 JObject job = JObject.Parse(kbtemp);
                 if (Int32.Parse(job["status"].ToString()) == 200)
                 {
                     JArray jarry = Utils.ReadJso(kbtemp);
                     for (int j = 0; j < jarry.Count; j++)
                     {
                         ClassListLight cll = new ClassListLight();
                         var istriple = cll.getattribute((JObject)jarry[j]);
                         cll.Name = new string[] { muIdList[i].uName }; // muIdList[i].uName;
                         if (istriple != null)
                         {
                             clist.Add(istriple);
                             istriple.Name = cll.Name;
                         }
                         clist.Add(cll);
                     }
                 }
                 issuccess = 2;
             }
             else
             {
                 issuccess++;
             }
         }
         forsearchlist.Add(muIdList[i].uName, clist);
         FreeLoddingProgressBar.Value = FreeLoddingProgressBar.Value + 100.0 / muIdList.Count;
         Debug.WriteLine(FreeLoddingProgressBar.Value);
     }
     //查无课表,参数第几周==
     EmptyClass ec = new EmptyClass(week, forsearchlist);
     ec.getfreetime(result, termresult);
     //freetime(11, forsearchlist);
     FreeLoddingStackPanel.Visibility = Visibility.Collapsed;
     FreeKBTableGrid.Visibility = Visibility.Visible;
     ShowWeekendAppBarButton.Visibility = Visibility.Visible;
     if (result.Count != 0)
         showFreeKB(result);
     else
         showFreeKB(termresult);
 }
开发者ID:RedrockMobile,项目名称:CyxbsMobile_Win,代码行数:56,代码来源:SearchFreeTimeResultPage_new.xaml.cs

示例2: CalendarWeekAppBarButton_Click

 /// <summary>
 /// 学期和周的切换
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void CalendarWeekAppBarButton_Click(object sender, RoutedEventArgs e)
 {
     if (week != -100)
     {
         week_old = week;
         week = -100;
         weekorterm = true;
         HubSectionKBNum.Visibility = Visibility.Collapsed;
         HubSectionKBNumD.Visibility = Visibility.Collapsed;
         HubSectionKBNumZ.Visibility = Visibility.Collapsed;
         ResultName.Initialize();
         EmptyClass ec = new EmptyClass(week, forsearchlist);
         ec.getfreetime(result, termresult);
         showFreeKB(termresult, showWeekend);
     }
     else
     {
         weekorterm = false;
         week = week_old;
         HubSectionKBNum.Text = week.ToString();
         HubSectionKBNum.Visibility = Visibility.Visible;
         HubSectionKBNumD.Visibility = Visibility.Visible;
         HubSectionKBNumZ.Visibility = Visibility.Visible;
         ResultName.Initialize();
         EmptyClass ec = new EmptyClass(week, forsearchlist);
         ec.getfreetime(result, termresult);
         showFreeKB(result, showWeekend);
     }
 }
开发者ID:RedrockMobile,项目名称:CyxbsMobile_Win,代码行数:34,代码来源:SearchFreeTimeResultPage_new.xaml.cs

示例3: ShowWeekendAppBarButton_Click

 /// <summary>
 /// 显示隐藏周末
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void ShowWeekendAppBarButton_Click(object sender, RoutedEventArgs e)
 {
     if (showWeekend)
         ShowWeekendAppBarButton.Label = "显示周末课表";
     else
         ShowWeekendAppBarButton.Label = "隐藏周末课表";
     showWeekend = !showWeekend;
     EmptyClass ec = new EmptyClass(week, forsearchlist);
     ec.getfreetime(result, termresult); if (week != -100)
     {
         showFreeKB(result, showWeekend);
     }
     else
     {
         showFreeKB(termresult, showWeekend);
     }
 }
开发者ID:RedrockMobile,项目名称:CyxbsMobile_Win,代码行数:22,代码来源:SearchFreeTimeResultPage_new.xaml.cs

示例4: KBNumSearch

 /// <summary>
 /// 输入周查课表
 /// </summary>
 private void KBNumSearch()
 {
     if (KBNumFlyoutTextBox.Text != "" && KBNumFlyoutTextBox.Text.IndexOf(".") == -1)
     {
         try
         {
             week = int.Parse(KBNumFlyoutTextBox.Text);
             HubSectionKBNum.Text = KBNumFlyoutTextBox.Text;
             KBNumFlyout.Hide();
             ResultName = new string[7, 6][];
             EmptyClass ec = new EmptyClass(week, forsearchlist);
             result = new ObservableCollection<ClassListLight>();
             ec.getfreetime(result, termresult);
             showFreeKB(result, showWeekend);
         }
         catch (Exception)
         {
             Utils.Message("请输入正确的周次");
         }
     }
     else
         Utils.Message("请输入正确的周次");
 }
开发者ID:RedrockMobile,项目名称:CyxbsMobile_Win,代码行数:26,代码来源:SearchFreeTimeResultPage_new.xaml.cs


注:本文中的EmptyClass.getfreetime方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。