Ejemplo n.º 1
0
        public void ReceiveMeasurement(Measurement measurement, string physcianName, string sessionType, string username)
        {
            UserClient userClient = (UserClient)server.GetUserFromPhysician(username);

            if (sessionType.Equals("Create"))
            {
                userClient.addSession(DateTime.Now);
            }
            else if (sessionType.Equals("CreateTest"))
            {
                userClient.StartNewTest();
            }
            else if (sessionType.Equals("AddToTest"))
            {
                userClient.AddToLatestTest(measurement);
            }
            else
            {
                userClient.addMeasurement(measurement);
                //ServerClient physician = server.getPhysicianClient(physcianName);
                //if (physician != null)
                //{
                //    Console.WriteLine("sending new user " + user.isOnline);
                //    NetworkFlow.SendPacket(new PacketGiveUserResponse(user), server.getPhysicianClient(((UserClient)user).physician).stream);
                //}
            }
        }
Ejemplo n.º 2
0
 public void addClient(UserClient client)
 {
     clients.Add(client);
 }
Ejemplo n.º 3
0
 public void addClient(UserClient client)
 {
     clients.Add(client);
 }