コード例 #1
0
        public void StuckLuggageRoleTest1()
        {
            StuckLuggageRole role = new StuckLuggageRole();
            //bool pass1 = role.Equals(new StuckLuggageRole());

            //Assert.IsFalse(pass1);
        }
コード例 #2
0
 public void HandleProblem()
 {
     StuckLuggageRole neededRole = new StuckLuggageRole();
     Personnel person = null;
     // Spin while no available person
     while (person == null)
     {
         Thread.Sleep(10);
         person = pc.acquirePersonWithRole(neededRole);
     }
     long end_time = DateTime.Now.Ticks + 10000 * TIMETOPROCESS;
     while (end_time > DateTime.Now.Ticks)
     {
         Thread.Sleep(10);
     }
     pc.returnPerson(person);
 }