Пример #1
0
    /// <summary>
    /// Loads the staff data.
    /// </summary>
    void LoadStaffData()
    {
        Staff temp;

        //building 245
        //Shri Rai
        temp = new Staff ();
        temp.SetName ("Shri Rai");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.019");
        temp.AddPhone ("9360 6090");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Senior Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Nik Thompson
        temp = new Staff ();
        temp.SetName ("Dr Nik Thompson");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.011");
        temp.AddPhone ("9360 1258");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("759.jpg");
        temp.SetPosition ("Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Fairuz Shiratuddin
        temp = new Staff ();
        temp.SetName ("Dr Mohd Fairuz Shiratuddin");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.014");
        temp.AddPhone ("9360 2794");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("341.jpg");
        temp.SetPosition ("Senior Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Christian Payne
        temp = new Staff ();
        temp.SetName ("Dr Christian Payne");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.015");
        temp.AddPhone ("9360 2778");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Lecturer - Information Technology");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Hong Xie
        temp = new Staff ();
        temp.SetName ("Dr Hong Xie");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.016");
        temp.AddPhone ("9360 6087");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Senior Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Kevin Wong
        temp = new Staff ();
        temp.SetName ("Dr Kevin Wong");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.018");
        temp.AddPhone ("9360 6100");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("511.gif");
        temp.SetPosition ("Associate Professor");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Danny Toohey
        temp = new Staff ();
        temp.SetName ("Danny Toohey");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.020");
        temp.AddPhone ("9360 2800");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Associate Dean for Learning and Teaching");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Peter Cole
        temp = new Staff ();
        temp.SetName ("Peter Cole");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.024");
        temp.AddPhone ("9360 2918");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("317.jpg");
        temp.SetPosition ("Senior Lecturer Information Technology");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Pyara Dhillon
        temp = new Staff ();
        temp.SetName ("Dr Pyara Dhillon");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.025");
        temp.AddPhone ("9360 2799");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Academic Head of Computer Science");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Graham Mann
        temp = new Staff ();
        temp.SetName ("Dr Graham Mann");
        temp.SetBuildingNo ("245");
        temp.SetOfficeNo("1.013");
        temp.AddPhone ("9360 7270");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("822.jpg");
        temp.SetPosition ("Senior Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Engineering and Information Technology");
        temp.AddOrganisation ("Information Technology");
        //add to staff manager
        sm.AddStaff (temp);

        //building 350
        //Pamela Martin-Lynch
        temp = new Staff ();
        temp.SetName ("Pamela Martin-Lynch");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.004");
        temp.AddPhone ("9360 2519");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("772.jpg");
        temp.SetPosition ("Lecturer");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Rebecca Bennett
        temp = new Staff ();
        temp.SetName ("Dr Rebecca Bennett");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.005");
        temp.AddPhone ("9360 2355");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("549.jpg");
        temp.SetPosition ("Lecturer Academic - Language and Literacy");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //Karyn Barenberg
        temp = new Staff ();
        temp.SetName ("Karyn Barenberg");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.007");
        temp.AddPhone ("9360 2142");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Administration Assistant");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Angela Jones
        temp = new Staff ();
        temp.SetName ("Dr Angela Jones");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.008");
        temp.AddPhone ("9360 6584");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("743.jpg");
        temp.SetPosition ("Administration Assistant");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //Professor Geoffrey Bolton
        temp = new Staff ();
        temp.SetName ("Professor Geoffrey Bolton");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("1.012");
        temp.AddPhone ("9360 6857");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Emeritus Professor");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Arts");
        //add to staff manager
        sm.AddStaff (temp);

        //Kate Makowiecka
        temp = new Staff ();
        temp.SetName ("Kate Makowiecka");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("3.012");
        temp.AddPhone ("9360 7491");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("University Copyright Coordinator");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Library and Information Services Office");
        temp.AddOrganisation ("Client Services and Information Access");
        temp.AddOrganisation ("Administration and Systems");
        temp.AddOrganisation("Library Administration");
        //add to staff manager
        sm.AddStaff (temp);

        //Sonia Boccardo
        temp = new Staff ();
        temp.SetName ("Sonia Boccardo");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("3.014");
        temp.AddPhone ("9360 6679");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Senior Librarian Reference and Liaison Services");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Library and Information Services Office");
        temp.AddOrganisation ("Client Services and Information Access");
        temp.AddOrganisation("Library Resource Services");
        //add to staff manager
        sm.AddStaff (temp);

        //Ghylene Palmer
        temp = new Staff ();
        temp.SetName ("Ghylene Palmer");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("3.015");
        temp.AddPhone ("9360 2763");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Acting Manager Library Client Services");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Library and Information Services Office");
        temp.AddOrganisation ("Client Services and Information Access");
        temp.AddOrganisation("Library Client Services");
        //add to staff manager
        sm.AddStaff (temp);

        //Joanne Lisciandro
        temp = new Staff ();
        temp.SetName ("Joanne Lisciandro");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.002A");
        temp.AddPhone ("9360 6258");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("902.jpg");
        temp.SetPosition ("Lecturer - OnTrack");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //Jodie-Lee McLeod
        temp = new Staff ();
        temp.SetName ("Jodie-Lee McLeod");
        temp.SetBuildingNo ("350");
        temp.SetOfficeNo("4.002B");
        temp.AddPhone ("9360 6220");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Postgraduate Training Coordinator");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Centre for University Teaching and Learning");
        //add to staff manager
        sm.AddStaff (temp);

        //building 460
        //Andrew Syme
        temp = new Staff ();
        temp.SetName ("Andrew Syme");
        temp.SetBuildingNo ("460");
        temp.SetOfficeNo("4.007");
        temp.AddPhone ("9360 7421");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Senior Database Coordinator");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Library and Information Services Office");
        temp.AddOrganisation ("Information Systems and Infrastructure");
        temp.AddOrganisation ("Computer Services");
        //add to staff manager
        sm.AddStaff (temp);

        //Abigayle Carmody
        temp = new Staff ();
        temp.SetName ("Abigayle Carmody");
        temp.SetBuildingNo ("460");
        temp.SetOfficeNo("1.007");
        temp.AddPhone ("9360 2719");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Equity Projects Officer");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Student Services");
        temp.AddOrganisation ("Equity & Social Inclusion");
        //add to staff manager
        sm.AddStaff (temp);

        //Nikola Horley
        temp = new Staff ();
        temp.SetName ("Supratik Mukherji");
        temp.SetBuildingNo ("460");
        temp.SetOfficeNo("1.011");
        temp.AddPhone ("9360 6152");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Student Disability Advisor");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Student Services");
        temp.AddOrganisation ("Equity & Social Inclusion");
        //add to staff manager
        sm.AddStaff (temp);

        //Supratik Mukherji
        temp = new Staff ();
        temp.SetName ("Supratik Mukherji");
        temp.SetBuildingNo ("460");
        temp.SetOfficeNo("1.014");
        temp.AddPhone ("9360 6060");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Student Disability Advisor");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("Student Services");
        temp.AddOrganisation ("Equity & Social Inclusion");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Courtney Field
        temp = new Staff ();
        temp.SetName ("Dr Courtney Field");
        temp.SetBuildingNo ("460");
        temp.SetOfficeNo("2.006");
        temp.AddPhone ("9360 2319");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Law");
        //add to staff manager
        sm.AddStaff (temp);

        //building 330
        //Linda Barton
        temp = new Staff ();
        temp.SetName ("Linda Barton");
        temp.SetBuildingNo ("330");
        temp.SetOfficeNo("3.023");
        temp.AddPhone ("9360 6435");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Manager HR Systems and Projects");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Human Resources Office");
        temp.AddOrganisation ("HR Systems");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Erich von Dietze
        temp = new Staff ();
        temp.SetName ("Dr Erich von Dietze");
        temp.SetBuildingNo ("330");
        temp.SetOfficeNo("1.006");
        temp.AddPhone ("9360 6170");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Manager Research Ethics");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Research And Development Office");
        temp.AddOrganisation ("Directorate Research & Development Office");
        temp.AddOrganisation ("Research Ethics");
        //add to staff manager
        sm.AddStaff (temp);

        //Dr Graham O'Hara
        temp = new Staff ();
        temp.SetName ("Dr Graham O'Hara");
        temp.SetBuildingNo ("330");
        temp.SetOfficeNo("1.009");
        temp.AddPhone ("9360 2583");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Senior Lecturer");
        temp.AddOrganisation ("Academy");
        temp.AddOrganisation ("School of Veterinary and Life Sciences");
        temp.AddOrganisation ("Agricultural Sciences");
        //add to staff manager
        sm.AddStaff (temp);

        //Joanne Hulme
        temp = new Staff ();
        temp.SetName ("Joanne Hulme");
        temp.SetBuildingNo ("330");
        temp.SetOfficeNo("2.005");
        temp.AddPhone ("9360 6352");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("Domestic Admissions Coordinator");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        temp.AddOrganisation ("External Engagement");
        temp.AddOrganisation("Admissions and Recruitment Support");
        //add to staff manager
        sm.AddStaff (temp);

        //Paul Comiskey
        temp = new Staff ();
        temp.SetName ("Paul Comiskey");
        temp.SetBuildingNo ("330");
        temp.SetOfficeNo("2.009");
        temp.AddPhone ("9360 7812");
        temp.SetEmail ("*****@*****.**");
        temp.SetPhoto ("none");
        temp.SetPosition ("MUCC Curriculum Manager ");
        temp.AddOrganisation ("Professional Services");
        temp.AddOrganisation ("Academic Registrar's Office");
        //add to staff manager
        sm.AddStaff (temp);

        //		//Load staff data here
        //		string dirInfo = Application.dataPath + "/Resources/Staff";
        //		string[] subdirectories = Directory.GetDirectories (dirInfo);
        //
        //		foreach (string d in subdirectories) //for each directory
        //		{
        //			Staff temp = new Staff ();
        //			DirectoryInfo dir = new DirectoryInfo(d);
        //			FileInfo[] files = dir.GetFiles(); //get list of files in the directory
        //
        //			foreach(FileInfo f in files) //for each file in the directory
        //			{
        //				if(!f.Name.Contains("meta")) //ignore if file name contains "meta" substring
        //				{
        //					string path = dir.Name;
        //					string file = Path.GetFileNameWithoutExtension(f.Name);
        //					TextAsset txtfile = Resources.Load("Staff/" + path + "/" + file) as TextAsset;
        //					char[] separators = {'\n'};
        //					string[] linesFromfile = txtfile.text.Split (separators);
        //					string[] tokens;
        //
        //					//phones
        //					int pIndex = 4; //index of first occupant
        //					tokens = linesFromfile[pIndex-1].Split(':'); //split "Number of Phones: " string
        //					int pCount = Int32.Parse (tokens[1].Trim()); //get number of phones
        //					//Debug.Log(pIndex + " " + pCount);
        //
        //					//organisations
        //					int oIndex = pIndex + pCount + 4; //index of first service
        //					tokens = linesFromfile[oIndex-1].Split(':'); //split "Number of Organisations: " string
        //					int oCount = Int32.Parse (tokens[1].Trim()); //get the number of organisations
        //					//Debug.Log(oIndex + " " + oCount);
        //
        //					//set staff name
        //					tokens = linesFromfile[0].Split(':');
        //					temp.SetName(tokens[1].Trim());
        //
        //					//set building number
        //					tokens = linesFromfile[1].Split(':');
        //					temp.SetBuildingNo(tokens[1].Trim());
        //
        //					//set office number
        //					tokens = linesFromfile[2].Split(':');
        //					temp.SetOfficeNo(tokens[1].Trim());
        //
        //					//add phones
        //					for(int i=pIndex; i<pIndex + pCount; i++)
        //					{
        //						temp.AddPhone(linesFromfile[i]);
        //					}
        //
        //					//set email
        //					tokens = linesFromfile[oIndex - 4].Split(':');
        //					temp.SetEmail(tokens[1].Trim());
        //
        //					//set photo
        //					tokens = linesFromfile[oIndex - 3].Split(':');
        //					temp.SetPhoto(tokens[1].Trim());
        //
        //					//set position
        //					tokens = linesFromfile[oIndex - 2].Split(':');
        //					temp.SetPosition(tokens[1].Trim());
        //
        //					//add organisations
        //					for(int i=oIndex; i<oIndex + oCount; i++)
        //					{
        //						temp.AddOrganisation(linesFromfile[i]);
        //					}
        //				}
        //
        //				sm.AddStaff (temp); //add the staff to the list
        //			}
        //		}

        //		Debug.Log (">>>No Staff");
        //		Debug.Log(sm.NumberOfStaff().ToString());
        //
        //		for(int i=0; i<sm.NumberOfStaff(); i++)
        //		{
        //			Debug.Log (">>>Staff Member");
        //			Debug.Log(sm.GetStaffAt(i).GetName());
        //			Debug.Log(sm.GetStaffAt(i).GetBuildingNo());
        //			Debug.Log(sm.GetStaffAt(i).GetOfficeNo());
        //
        //			Debug.Log (">>>Phones");
        //			for(int j=0; j<sm.GetStaffAt(i).NumberOfPhones(); j++)
        //				Debug.Log(sm.GetStaffAt(i).GetPhoneAt(j));
        //
        //			Debug.Log(sm.GetStaffAt(i).GetEmail());
        //			Debug.Log(sm.GetStaffAt(i).GetPhoto());
        //			Debug.Log(sm.GetStaffAt(i).GetPosition());
        //
        //			Debug.Log (">>>Organisations");
        //			for(int j=0; j<sm.GetStaffAt(i).NumberOfOrganisations(); j++)
        //				Debug.Log(sm.GetStaffAt(i).GetOrganisationAt(j));
        //		}
    }