コード例 #1
0
        public Research GetResearchInformation()
        {
            // get research information
            string jsonResearch = GetRestData(AppConstant.ResearchPage);

            Research research = JToken.Parse(jsonResearch).ToObject <Research>();

            return(research);
        }
コード例 #2
0
        public void Populate()
        {
            research = _dataService.GetResearchInformation();

            foreach (ByInterestArea interestArea in research.byInterestArea)
            {
                if (interestArea.AreaName == "HCI")
                {
                    groupBoxHCI.Text = interestArea.AreaName;
                    textBoxHCI.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxHCI.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Analytics")
                {
                    groupBoxAnalytics.Text = interestArea.AreaName;
                    textBoxAnalytics.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxAnalytics.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Database")
                {
                    groupBoxDatabase.Text = interestArea.AreaName;
                    textBoxDatabase.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxDatabase.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Education")
                {
                    groupBoxEducation.Text = interestArea.AreaName;
                    textBoxEducation.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxEducation.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Geo")
                {
                    groupBoxGeo.Text = interestArea.AreaName;
                    textBoxGeo.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxGeo.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Health Informatics")
                {
                    groupBoxHealthInformatics.Text = interestArea.AreaName;
                    textBoxHealthInformatics.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxHealthInformatics.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Mobile")
                {
                    groupBoxMobile.Text = interestArea.AreaName;
                    textBoxMobile.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxMobile.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Networking")
                {
                    groupBoxNetworking.Text = interestArea.AreaName;
                    textBoxNetworking.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxNetworking.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Programming")
                {
                    groupBoxProgramming.Text = interestArea.AreaName;
                    textBoxProgramming.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxProgramming.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "System Administration")
                {
                    groupBoxSystemAdmin.Text = interestArea.AreaName;
                    textBoxSystemAdmin.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxSystemAdmin.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Ubiquitous Computing")
                {
                    groupBoxUbiquitous.Text = interestArea.AreaName;
                    textBoxUbiquitous.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxUbiquitous.Text += "* " + citation + "\r\n";
                    }
                }

                if (interestArea.AreaName == "Web")
                {
                    groupBoxWeb.Text = interestArea.AreaName;
                    textBoxWeb.Text  = "Citations : " + "\r\n";

                    foreach (var citation in interestArea.Citations)
                    {
                        textBoxWeb.Text += "* " + citation + "\r\n";
                    }
                }
            }

            foreach (ByFaculty byFaculty in research.byFaculty)
            {
                if (byFaculty.FacultyName == "Deborah Gears")
                {
                    groupBoxDG.Text = byFaculty.FacultyName;
                    labelDG.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxDG.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Brian Tomaszewski")
                {
                    groupBoxBT.Text = byFaculty.FacultyName;
                    labelBT.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxBT.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Elissa Weeden")
                {
                    groupBoxEW.Text = byFaculty.FacultyName;
                    labelEW.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxEW.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Qi Yu")
                {
                    groupBoxQY.Text = byFaculty.FacultyName;
                    labelQY.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxQY.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Steve Zilora")
                {
                    groupBoxSZ.Text = byFaculty.FacultyName;
                    labelSZ.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxSZ.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Catherine Beaton")
                {
                    groupBoxCB.Text = byFaculty.FacultyName;
                    labelCB.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxCB.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Bruce Hartpence")
                {
                    groupBoxBH.Text = byFaculty.FacultyName;
                    labelBH.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxBH.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Sharon Mason")
                {
                    groupBoxSM.Text = byFaculty.FacultyName;
                    labelSM.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxSM.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Tae (Tom) Oh")
                {
                    groupBoxTO.Text = byFaculty.FacultyName;
                    labelTO.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxTO.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Nirmala Shenoy")
                {
                    groupBoxNS.Text = byFaculty.FacultyName;
                    labelNS.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxNS.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Ed Holden")
                {
                    groupBoxEH.Text = byFaculty.FacultyName;
                    labelEH.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxEH.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Michael Floeser")
                {
                    groupBoxMF.Text = byFaculty.FacultyName;
                    labelMF.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxMF.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Vicki Hanson")
                {
                    groupBoxVH.Text = byFaculty.FacultyName;
                    labelVH.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxVH.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Larry Hill")
                {
                    groupBoxLH.Text = byFaculty.FacultyName;
                    labelLH.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxLH.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Deborah LaBelle")
                {
                    groupBoxDL.Text = byFaculty.FacultyName;
                    labelDL.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxDL.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Ronald Vullo")
                {
                    groupBoxRV.Text = byFaculty.FacultyName;
                    labelRV.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxRV.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Matt Huenerfauth")
                {
                    groupBoxMH.Text = byFaculty.FacultyName;
                    labelMH.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxMH.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Charlie Border")
                {
                    groupBoxChB.Text = byFaculty.FacultyName;
                    labelChB.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxChB.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Daniel Ashbrook")
                {
                    groupBoxDA.Text = byFaculty.FacultyName;
                    labelDA.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxDA.Text += "* " + citation + "\r\n";
                    }
                }

                if (byFaculty.FacultyName == "Jai Kang")
                {
                    groupBoxJK.Text = byFaculty.FacultyName;
                    labelJK.Text    = "Username : "******"Citations : " + "\r\n";

                    foreach (var citation in byFaculty.Citations)
                    {
                        textBoxJK.Text += "* " + citation + "\r\n";
                    }
                }
            }
        }