Exemple #1
0
 public void Execute()
 {
     new Task(() =>
     {
         while (true)
         {
             foreach (var hardware in hardwareRepository
                      .GetHardwares(LOCAL_SCHOOL_ID))
             {
                 base.Execute(null, DuplexMessage.CreateCommandMessage(
                                  string.Empty,
                                  MessageVersion.V1,
                                  CommandCode.Test,
                                  Rpc.Net.Message.Filter.MessageFilterType.None,
                                  new byte[0],
                                  Rpc.Net.Message.Serializer.SerializeMode.None,
                                  new { DestinationAddr = hardware.Address }));
                 are.WaitOne(500);
             }
         }
     }).Start();
 }