Пример #1
0
 private void Notify()
 {
     lock (int_lock)
     {
         if (status < magics.Count)
         {
             Task.Run(() => process(status)); status++; mtx++;
         }
         if (status >= magics.Count && mtx == 0)
         {
             lock (new_article) File.WriteAllText("403.json", LogEssential.SerializeObject(new_article));
         }
     }
 }
Пример #2
0
 private void Notify()
 {
     lock (int_lock)
     {
         int i = status;
         if (i < maximum)
         {
             Task.Run(() => process(i)); status++; mtx++;
         }
         if (i >= maximum && mtx == 0)
         {
             lock (result) File.WriteAllText("gallery_block.json", LogEssential.SerializeObject(result));
         }
     }
 }
Пример #3
0
 private void button2_Click(object sender, EventArgs e)
 {
     lock (result) File.WriteAllText("gallery_block.json", LogEssential.SerializeObject(result));
     PushString("완료됨!");
 }
Пример #4
0
 private void timer1_Tick(object sender, EventArgs e)
 {
     lock (result) File.WriteAllText($"snapshot_{DateTime.Now.Ticks.ToString()}.json", LogEssential.SerializeObject(result));
 }