Class ScanApplication.ScanningTask
java.lang.Object
org.scictrl.csshell.epics.server.application.ScanApplication.ScanningTask
- All Implemented Interfaces:
Runnable
- Enclosing class:
ScanApplication
Runnable performing scan.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Interface that facilitates connection to undelaying services and context. -
Constructor Summary
ConstructorDescriptionScanningTask
(double start, double end, double step, long rate, int count, ScanApplication.Repeat repeat, double precision, ScanApplication.ScanningTask.ScanController ctrl, int overflowCount) Creates scan/ramp task -
Method Summary
Modifier and TypeMethodDescriptionvoid
abort()
Abort scan.void
cancel()
Cancels and aborts the scan.Returns next time step should happen, could be null if there is no next stepboolean
Returnstrue
if scan has been aborted.boolean
Returnstrue
if scan has been canceled.void
ramp
(double rStart, double rEnd, double rStep) Ramps remote value from start to end in steps.void
run()
-
Constructor Details
-
ScanningTask
public ScanningTask(double start, double end, double step, long rate, int count, ScanApplication.Repeat repeat, double precision, ScanApplication.ScanningTask.ScanController ctrl, int overflowCount) Creates scan/ramp task- Parameters:
start
- the start valueend
- the end valuestep
- the step sizerate
- the time to wait between steps in mscount
- the repetition count, 0 means one run without repetitionrepeat
- repetition specificationprecision
- value precision, determines how precise end value can bectrl
- the scan control that provides underlying context servicesoverflowCount
- hard limit that prevents runaway stepping
-
-
Method Details
-
getNextStepTime
Returns next time step should happen, could be null if there is no next step- Returns:
- next time step should happen
-
abort
public void abort()Abort scan. Scan progress is stopped. ScanController is notified that scan has been aborted. -
cancel
public void cancel()Cancels and aborts the scan. Scan progress is stopped, there is no notification to ScanController. -
isCanceled
public boolean isCanceled()Returnstrue
if scan has been canceled.- Returns:
true
if scan has been canceled
-
isAborted
public boolean isAborted()Returnstrue
if scan has been aborted.- Returns:
true
if scan has been aborted
-
run
public void run() -
ramp
public void ramp(double rStart, double rEnd, double rStep) Ramps remote value from start to end in steps.- Parameters:
rStart
- start valuerEnd
- end valuerStep
- step size
-