This class is used for updating the values SECI has stored for the blocks and from the DAE. It contains an instance of the BackgroundWorker class that is used as a separate thread for retrieving the current experiment values, and an instance of the Timer class which fires off the BackgroundWorkers every x milliseconds.
More...
|
void | Dispose () |
| The dispose method to be called from code. More...
|
|
void | PauseUpdater () |
| Method for pausing the timer. This is done by setting the delay and period to infinity. More...
|
|
void | ResumeUpdater () |
| Method for resuming the timer. This is done by setting the delay and period to their normal values. More...
|
|
void | StartUpdater () |
| Method for starting the timer, which fires off the update thread. More...
|
|
delegate void | ValuesUpdatedEventHandler (Boolean timeout) |
| Event for indicating to the GUI level that the values were updated. More...
|
|
| ValuesUpdater (int updateRate) |
| Constructor. Initialises the BackgroundWorker object. More...
|
|
|
static void | LogValuesAtStartOrEndRun (DateTime time, string runNumber) |
| Calls the method to log the blocks at the start or end of a run. If logging the end of a run, then need to use previous run number. More...
|
|
|
virtual void | Dispose (bool disposing) |
| If the value passed it true then the method has been called directly or indirectly from SECI code. If the value passed is false then the method has been called by the runtime from inside the finalizer. More...
|
|
|
void | _daeUpdater_DoWork (object sender, DoWorkEventArgs e) |
| The method that is run on the BackgroundWorker thread. More...
|
|
void | _daeUpdater_RunWorkerCompleted (object sender, RunWorkerCompletedEventArgs e) |
| The method that is run once the BackgroundWorker thread is finished. This raises an OnValuesUpdated event. More...
|
|
void | blockUpdater_DoWork (object sender, System.ComponentModel.DoWorkEventArgs e) |
| The method that is run on the BackgroundWorker thread. More...
|
|
void | blockUpdater_RunWorkerCompleted (object sender, System.ComponentModel.RunWorkerCompletedEventArgs e) |
| The method that is run once the BackgroundWorker thread is finished. This raises an OnValuesUpdated event. More...
|
|
void | createStatusBlock () |
|
void | updateTimer_Tick (object obj) |
| The method that is called when the timer ticks. If the BackgroundWorker thread is not busy it will request that it starts running. More...
|
|
This class is used for updating the values SECI has stored for the blocks and from the DAE. It contains an instance of the BackgroundWorker class that is used as a separate thread for retrieving the current experiment values, and an instance of the Timer class which fires off the BackgroundWorkers every x milliseconds.
Definition at line 16 of file ValuesUpdater.cs.
Seci.Tools.ValuesUpdater.ValuesUpdater |
( |
int |
updateRate | ) |
|
|
inline |
Constructor. Initialises the BackgroundWorker object.
- Parameters
-
updateRate | The rate at which the values should be updated in milliseconds |
Definition at line 37 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater._daeUpdater_DoWork |
( |
object |
sender, |
|
|
DoWorkEventArgs |
e |
|
) |
| |
|
inlineprivate |
The method that is run on the BackgroundWorker thread.
- Parameters
-
sender | The sender |
e | The event arguments |
Definition at line 202 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater._daeUpdater_RunWorkerCompleted |
( |
object |
sender, |
|
|
RunWorkerCompletedEventArgs |
e |
|
) |
| |
|
inlineprivate |
The method that is run once the BackgroundWorker thread is finished. This raises an OnValuesUpdated event.
- Parameters
-
sender | The sender |
e | The event arguments |
Definition at line 253 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.blockUpdater_DoWork |
( |
object |
sender, |
|
|
System.ComponentModel.DoWorkEventArgs |
e |
|
) |
| |
|
inlineprivate |
void Seci.Tools.ValuesUpdater.blockUpdater_RunWorkerCompleted |
( |
object |
sender, |
|
|
System.ComponentModel.RunWorkerCompletedEventArgs |
e |
|
) |
| |
|
inlineprivate |
The method that is run once the BackgroundWorker thread is finished. This raises an OnValuesUpdated event.
- Parameters
-
sender | The sender |
e | The event arguments |
Definition at line 188 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.createStatusBlock |
( |
| ) |
|
|
inlineprivate |
void Seci.Tools.ValuesUpdater.Dispose |
( |
| ) |
|
|
inline |
virtual void Seci.Tools.ValuesUpdater.Dispose |
( |
bool |
disposing | ) |
|
|
inlineprotectedvirtual |
If the value passed it true then the method has been called directly or indirectly from SECI code. If the value passed is false then the method has been called by the runtime from inside the finalizer.
- Parameters
-
disposing | Indicates where the call has come from |
Definition at line 300 of file ValuesUpdater.cs.
static void Seci.Tools.ValuesUpdater.logStatusBlock |
( |
Boolean |
force | ) |
|
|
inlinestaticprivate |
static void Seci.Tools.ValuesUpdater.LogValuesAtStartOrEndRun |
( |
DateTime |
time, |
|
|
string |
runNumber |
|
) |
| |
|
inlinestatic |
Calls the method to log the blocks at the start or end of a run. If logging the end of a run, then need to use previous run number.
- Parameters
-
time | The log time |
runNumber | The appropriate run number |
Definition at line 264 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.PauseUpdater |
( |
| ) |
|
|
inline |
Method for pausing the timer. This is done by setting the delay and period to infinity.
Definition at line 93 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.ResumeUpdater |
( |
| ) |
|
|
inline |
Method for resuming the timer. This is done by setting the delay and period to their normal values.
Definition at line 104 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.StartUpdater |
( |
| ) |
|
|
inline |
Method for starting the timer, which fires off the update thread.
Definition at line 81 of file ValuesUpdater.cs.
void Seci.Tools.ValuesUpdater.updateTimer_Tick |
( |
object |
obj | ) |
|
|
inlineprivate |
The method that is called when the timer ticks. If the BackgroundWorker thread is not busy it will request that it starts running.
- Parameters
-
Definition at line 117 of file ValuesUpdater.cs.
delegate void Seci.Tools.ValuesUpdater.ValuesUpdatedEventHandler |
( |
Boolean |
timeout | ) |
|
Event for indicating to the GUI level that the values were updated.
BackgroundWorker Seci.Tools.ValuesUpdater._blockUpdater |
|
private |
BackgroundWorker Seci.Tools.ValuesUpdater._daeUpdater |
|
private |
Boolean Seci.Tools.ValuesUpdater._daeUpdating = false |
|
private |
BlockInfo Seci.Tools.ValuesUpdater._statusBlock |
|
staticprivate |
Boolean Seci.Tools.ValuesUpdater._timedOut = false |
|
private |
TimerCallback Seci.Tools.ValuesUpdater._updateCallBack |
|
private |
int Seci.Tools.ValuesUpdater._updateRate = 500 |
|
private |
Timer Seci.Tools.ValuesUpdater._updateTimer |
|
private |
The documentation for this class was generated from the following file:
- /isis2/instcontrol_temp/NewSECI/Sample_Environment_Control_Interface/Seci/Tools/ValuesUpdater.cs