Esempio n. 1
0
 async void houseKeepingTimer_Elapsed(object sender, ElapsedEventArgs e)
 {
     using (var hl7Parser = new HL7Parser(httpClient))
     {
         await hl7Parser.FillWardCache();
         await hl7Parser.RemovBedsFromWards();
     }
 }
Esempio n. 2
0
 protected override bool HandleException(Exception ex)
 {
     httpClient.ClearCache();
     var t = Task.Run(async () =>
     {
         using (var hl7Parser = new HL7Parser(httpClient))
             await hl7Parser.FillWardCache();
     });
     t.Wait();
     return false;
 }
Esempio n. 3
0
 public override void Start()
 {
     var t = Task.Run(async () =>
     {
         using (var hl7Parser = new HL7Parser(httpClient))
             await hl7Parser.FillWardCache();
     });
     t.Wait();
     //houseKeepingTimer_Elapsed(null, null);
     base.Start();
     houseKeepingTimer.Start();
 }
Esempio n. 4
0
 protected override async Task ProcessFile(Stream stream)
 {
     using (var hl7Parser = new HL7Parser(stream, httpClient))
         await hl7Parser.Parse();
 }